mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-29 08:01:23 +03:00
Add support for RANGE window frames. Some cases still do not work.
FossilOrigin-Name: ffc32b246d92d53c66094afe11950b53ffab6a1c230c602eebbfedafb2eb57f4
This commit is contained in:
@ -219,17 +219,17 @@ do_execsql_test 9.0 {
|
||||
} {
|
||||
1 1 2 1,2 3 1,2,3 4 2,3,4 5 3,4,5
|
||||
}
|
||||
do_catchsql_test 9.1 {
|
||||
WITH RECURSIVE c(x) AS (VALUES(1) UNION ALL SELECT x+1 FROM c WHERE x<5)
|
||||
SELECT x, group_concat(x) OVER (ORDER BY x RANGE 2 PRECEDING)
|
||||
FROM c;
|
||||
} {1 {RANGE must use only UNBOUNDED or CURRENT ROW}}
|
||||
|
||||
do_catchsql_test 9.2 {
|
||||
WITH RECURSIVE c(x) AS (VALUES(1) UNION ALL SELECT x+1 FROM c WHERE x<5)
|
||||
SELECT x, group_concat(x) OVER (ORDER BY x RANGE BETWEEN UNBOUNDED PRECEDING AND 2 FOLLOWING)
|
||||
FROM c;
|
||||
} {1 {RANGE must use only UNBOUNDED or CURRENT ROW}}
|
||||
#do_catchsql_test 9.1 {
|
||||
# WITH RECURSIVE c(x) AS (VALUES(1) UNION ALL SELECT x+1 FROM c WHERE x<5)
|
||||
# SELECT x, group_concat(x) OVER (ORDER BY x RANGE 2 PRECEDING)
|
||||
# FROM c;
|
||||
#} {1 {RANGE must use only UNBOUNDED or CURRENT ROW}}
|
||||
#
|
||||
#do_catchsql_test 9.2 {
|
||||
# WITH RECURSIVE c(x) AS (VALUES(1) UNION ALL SELECT x+1 FROM c WHERE x<5)
|
||||
# SELECT x, group_concat(x) OVER (ORDER BY x RANGE BETWEEN UNBOUNDED PRECEDING AND 2 FOLLOWING)
|
||||
# FROM c;
|
||||
#} {1 {RANGE must use only UNBOUNDED or CURRENT ROW}}
|
||||
|
||||
do_catchsql_test 9.3 {
|
||||
WITH RECURSIVE c(x) AS (VALUES(1) UNION ALL SELECT x+1 FROM c WHERE x<5)
|
||||
@ -262,7 +262,7 @@ foreach {tn frame} {
|
||||
SELECT count() OVER (
|
||||
ORDER BY x ROWS $frame
|
||||
) FROM c;
|
||||
" {1 {unsupported frame delimiter for ROWS}}
|
||||
" {1 {unsupported frame specification}}
|
||||
}
|
||||
|
||||
do_catchsql_test 9.8.1 {
|
||||
|
Reference in New Issue
Block a user