aboutsummaryrefslogtreecommitdiff
path: root/src/window.c
Commit message (Collapse)AuthorAge
...
* Remove incorrect ALWAYS() macros from the window function logic.drh2018-07-10
| | | FossilOrigin-Name: 94ac51cc4e7fdf484214e1936fc96104b96134632a8eb99558b3af743ac8bb8b
* Add VdbeModuleComment()s on the three main code generators for windowdrh2018-07-10
| | | | | functions. FossilOrigin-Name: f7c239e959004cb90dc8537ab2e1fca5f26ef21f4f6f3dfd743a05a55e705090
* Minor comment changes. Add ALWAYS() macros on some unreachable branchesdrh2018-07-10
| | | | | in the xStep() methods of built-in window functions. FossilOrigin-Name: f2057542cf6860badb4ae6b1a0df94a78d5b2661dabf16f5705b3f8236521bea
* Fix a problem with using scalar sub-selects in window function queries.dan2018-07-10
| | | FossilOrigin-Name: 687fe532c274265ca77451f97829743fcb8a714d0f6b1ceb9a147ab9babdc5b5
* Further improvements to bytecode branch testing. Fix cases where thedrh2018-07-10
| | | | | | | macros said a branch could not be taken when in fact it could be. Alter some window function branch coverage macros to indicate that comparison operands cannot be NULL. FossilOrigin-Name: 76e42b7071a71137c0da4f10db4e653ae94a89b56e95cd3f036bff08c9500d08
* New VDBE comments and coverage macros.drh2018-07-10
| | | FossilOrigin-Name: a9a307265b0626b3e9df69534c8eacf18413ea31784c9d931eadcff515d3dd84
* Fixes for various harmless compiler warnings.drh2018-07-09
| | | FossilOrigin-Name: 5023b1b85b883a716a5da673740b6effe214ee0490f4ca45f161bb8b04784366
* Remove redundant branches in window function processing.drh2018-07-09
| | | FossilOrigin-Name: 8fdaf3f37e5ddac9b7337a50f32f5d2bcdd64780797f08cfd3fccfa95819edfe
* Throw an error if the second argument passed to nth_value() is not a positivedan2018-07-09
| | | | | integer. FossilOrigin-Name: 1a06e57a0b4279fa580c7ff4f152645f005794aaf86eeabf694637b7da11f763
* Fix a bad assert() in window.c.dan2018-07-09
| | | FossilOrigin-Name: fe8aaf0c806413965f50a03e34b5fdfaaa8b09dc0af73f41e830f7b664bd1ced
* Identify specific FuncDef objects for window functions using the pointer todrh2018-07-08
| | | | | | | the function name (FuncDef.zName) rather than the pointer to the xStep method. This allows xStep method pointer to be replaced with a single noopStepFunc() procedure, and thus save having lots of different no-op step functions. FossilOrigin-Name: 410e13b0e0fb6e040808f076014d55ecf2b541c5439b4fd53c5bdcb8d800098e
* Add missing VdbeCoverage() macro to window.c.dan2018-07-07
| | | FossilOrigin-Name: 63f4d306ba19f6ba900a7d7480ccaa3d1e4a204e7c82bf5eb2e4bd849ef3a22f
* Fix a problem with the handling of NULL values in the min() window function.dan2018-07-07
| | | FossilOrigin-Name: b76f35b09235d44dc3d176377bbb9c18b7cdc9392800103ff53c54730a427a5c
* Try to improve the error messages for misformed frame specifications indrh2018-07-06
| | | | | window definitions. FossilOrigin-Name: 927b95a0812787bcb3c28d1a0ea94717dc2cc60f6d480623f0c7cbce0c546fc9
* Also disallow non-constant expressions in "<expr> PRECEDING" or "<expr>dan2018-07-06
| | | | | FOLLOWING" clauses. FossilOrigin-Name: a6dffecc6b35c618cc5e5a06892765bdbec587dcd0ae8686c231a21516e38eab
* Ensure an error is returned if the user specifies an unsupported frame type.dan2018-07-06
| | | FossilOrigin-Name: 0f3f8fcde1a535bcf93e23a68d2411c21785d8c0cac1f9481a06e7225755cdbc
* Remove some bad assert() statements from the implementations of windowdan2018-07-06
| | | | | functions percent_rank() and cume_dist(). FossilOrigin-Name: 443f0c286f1659937fd61b4ef2de17d0d015369e5ff5249a9e0c3d0ee4925158
* Return an error if DISTINCT is used with a window-function (.i.e.dan2018-07-06
| | | | | "count(DISTINCT <expr>) OVER (...)". FossilOrigin-Name: d59bcc8eea4fcf0ee3c2263d31ee42f9f26c28434d2f0045f2d3329f18791d1c
* Use separate opcodes, OP_AggValue and OP_AggInverse, for the new callbacksdrh2018-07-05
| | | | | | associated with Window Functions, for improved readability of EXPLAIN output. FossilOrigin-Name: fa6538050938ffeb042fbee31512514d6d3ace514b2a3dfd8365bbeb13f35a78
* Return an error if a "RANGE" window-frame uses "<expr> PRECEDING" or "<expr>dan2018-07-05
| | | | | FOLLOWING". FossilOrigin-Name: 786c87ba4150509e141baab32c51e64bbd3ce323735e0f47d65ed54d14215bc4
* Fix a segfault caused by invoking a regular aggregate as a window-function.dan2018-07-02
| | | | | And some problems with count(*) when used as a window-function. FossilOrigin-Name: 4f3c8a82fd1c5b14d84f2301e34cfc8d52fe4b3a60840c39e895c11f2da529d9
* Add missing VdbeCoverage() and VdbeCoverageNeverTaken() macros to window.c.dan2018-06-27
| | | FossilOrigin-Name: 4383cb68a1241768ddb3f180f8cbb9ea1638f8806210b10aac1384b8a7ecdca2
* Avoid redundant ORDER BY operations when rewriting SELECT statements thatdan2018-06-27
| | | | | contain window functions. FossilOrigin-Name: 336de43a47e206fe7629072e5b8c80d4ede17ead8ef4dcf5d8da6833ff22d2f9
* Omit all window-function related code when building with SQLITE_OMIT_WINDOWFUNC.dan2018-06-22
| | | FossilOrigin-Name: 5f04b016467342b5a796bf702ed25b621eb86f2961c1e703d276c93f2cb6aa89
* Merge latest trunk changes.dan2018-06-22
| | | FossilOrigin-Name: ebe65b2386a6132f4ef2cce6668a2da7db0798a70d2fba652882d5bccfd6672b
* Fix a problem with handling single row partitions in the percent_rank() windowdan2018-06-21
| | | | | function. FossilOrigin-Name: b84fbf16eac718c151731e2b2dcc73f2f2a144e3670f8566a30793f1e4e6a3ec
* Add tests to improve coverage of code in window.c. Fix a problem with "SELECTdan2018-06-20
| | | | | row_number() OVER ()". FossilOrigin-Name: f41b6b7317e2b5ac5721a3adff49f298ded29f9e0f887af98faeb0cb7e865ab6
* Fix problems with using window functions in CREATE VIEW statements.dan2018-06-18
| | | FossilOrigin-Name: 943bccd2a6bd4cf3e0534c1fa46885bfa2ba7b780ddcdff9f1ea4cbb3f04e786
* Add new API function sqlite3_create_window_function(), for creating newdan2018-06-18
| | | | | aggregate window functions. FossilOrigin-Name: da03fb4318fd2613ec5c5b109a3974ac1120c19ed16bed4ca85bbdc4b35c998c
* Add extra OOM test.dan2018-06-15
| | | FossilOrigin-Name: ac251f72608c27c1512a0b3457524f5378a0b13d93d829cf0ed8bc178bc54a73
* Fix another problem in lead()/lag(). And some errors that could occurdan2018-06-15
| | | | | following OOM faults. FossilOrigin-Name: fadd4dc119d8df0d871f4d839b7a11070e2ffb8927e84b3e7a94f34196db3de3
* Fix a bug in the lead() and lag() window functions causing them to fail whendan2018-06-15
| | | | | used in queries featuring multiple window functions. FossilOrigin-Name: 3839fb18f917e4f705821198d624b19d84eb07f1ee29ad23314ab7cec6bf6a2b
* Fix a problem with handling of statements containing two or more differentdan2018-06-14
| | | | | windows. FossilOrigin-Name: 567e09ef2a8cd84a2481117e52595bed0f3b588745a9e441aae0f87680f3a2e8
* Fix problem with window functions min() and max() when used with a PARTITIONdan2018-06-14
| | | | | clause and a frame starting point other than "UNBOUNDED PRECEDING". FossilOrigin-Name: 43eb1e75a4d7ac0973ed8589bbaf379c24cdc8eacc4e613610d2d4c24d385dc1
* Improve comments and code legibility in new file window.c.dan2018-06-14
| | | FossilOrigin-Name: bb915854d435bdd78f141d70e23527e97922ec176acd3ed8060c78dffc96bab8
* Fix problems with "RANGE BETWEEN CURRENT ROW AND UNBOUNDED FOLLOWING" windowdan2018-06-13
| | | | | frames. FossilOrigin-Name: c34f31dbd79891249ee9485e91f6ea558ee1db62e04fb0fff2c051612b8fa5e7
* Fix another issue to do with window-functions in aggregate queries.dan2018-06-12
| | | FossilOrigin-Name: 6413e38a174044c28fa9b8b937e6c972d144547a246e6f2882e782538300d042
* Fix some problems with using window-functions in aggregate queries.dan2018-06-12
| | | FossilOrigin-Name: fe7081e0952950f577234fcbb58f3c1efa4579267654fd2f713dc4804e470e7e
* Clarify the relationship between a Window object and its associated Expr.dan2018-06-11
| | | FossilOrigin-Name: 0cd55e98a478740032f5569ddc00fa5b0e063e90db6e00ac7598c9b7c2fffeee
* Fix handling of window frames containing negative number of rows. e.g. "ROWS xdan2018-06-11
| | | | | PRECEDING AND y PRECEDING" where (x<y). FossilOrigin-Name: b6d9c7eda853420ae46a05bd432711e8bf9ebaa448c7d90ccfc0bcc338a87706
* Add support for FILTER clause on aggregate window functions.dan2018-06-09
| | | FossilOrigin-Name: ceaf798ea09184bc0e7d3dcf3ad4d909d2e4e7018754a8417a813f33010140a7
* Add support for the WINDOW clause.dan2018-06-08
| | | FossilOrigin-Name: 19c983b511f1c823fdfb051713681b4c779f02fa83b41189afca0a9b8b72048d
* Do not flatten sub-queries that contain window functions.dan2018-06-08
| | | FossilOrigin-Name: 236cb75bd1f0d5eb86aa5f52d8d548e7263c34633833dcea9dfc934f142113b8
* Add window functions lag() and lead().dan2018-06-07
| | | FossilOrigin-Name: ef34207073c21ce8618486777671ae78d23f290acd6d3c37e91a49b69cb506ac
* Add support for window function first_value().dan2018-06-07
| | | FossilOrigin-Name: 060b26402880daab085ad01f5f0dbde957c7a22cd219be5b8ec94fba883051a0
* Fix problems with the nth_value() function.dan2018-06-07
| | | FossilOrigin-Name: 63002b9a090397668b94fe341a035c42f84e4837af85395bce4cd1c2777c5209
* Add implementation of nth_value() window function.dan2018-06-06
| | | FossilOrigin-Name: eb1fb420ac70857e7ca4cbad78be15a27bee8f915ba2da080c7efa1879c06c31
* Add implementation of last_value() window function.dan2018-06-05
| | | FossilOrigin-Name: 2493ce1a402888f6a8f25e03052c25a4e9bca740639e98cb614f5e5160ac25d3
* Add implementation of window function ntile().dan2018-06-04
| | | FossilOrigin-Name: 3f093f608c6cc193aac77e7eafa8006c27a7776682d9d7b6e743710dff41ae42
* Add support for window function cume_dist(). Improve tests for percent_rank().dan2018-06-04
| | | FossilOrigin-Name: 76543f7dd3a2310f6e81a1bae17db9bb5d2cf10c1b87ed3f8394b3e75576078b