-
Notifications
You must be signed in to change notification settings - Fork 595
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into xxh/decouple_default_1
- Loading branch information
Showing
96 changed files
with
2,208 additions
and
928 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
include ./generated/main.slt.part | ||
include ./session/mod.slt.part |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# Because currently general streaming version of session window is not supported yet, | ||
# we only add e2e for batch mode. | ||
|
||
statement ok | ||
create table t ( | ||
tm timestamp, | ||
foo int, | ||
bar int | ||
); | ||
|
||
statement ok | ||
create view v1 as | ||
select | ||
*, | ||
first_value(tm) over (partition by bar order by tm session with gap '10 minutes') as window_start, | ||
last_value(tm) over (partition by bar order by tm session with gap '10 minutes') as window_end | ||
from t; | ||
|
||
statement ok | ||
insert into t values | ||
('2023-05-06 16:51:00', 1, 100) | ||
, ('2023-05-06 16:56:00', 8, 100) | ||
, ('2023-05-06 17:30:00', 3, 200) | ||
, ('2023-05-06 17:35:00', 5, 100) | ||
, ('2023-05-06 17:59:00', 4, 100) | ||
, ('2023-05-06 18:01:00', 6, 200) | ||
; | ||
|
||
query TiiTT | ||
select * from v1 order by tm; | ||
---- | ||
2023-05-06 16:51:00 1 100 2023-05-06 16:51:00 2023-05-06 16:56:00 | ||
2023-05-06 16:56:00 8 100 2023-05-06 16:51:00 2023-05-06 16:56:00 | ||
2023-05-06 17:30:00 3 200 2023-05-06 17:30:00 2023-05-06 17:30:00 | ||
2023-05-06 17:35:00 5 100 2023-05-06 17:35:00 2023-05-06 17:35:00 | ||
2023-05-06 17:59:00 4 100 2023-05-06 17:59:00 2023-05-06 17:59:00 | ||
2023-05-06 18:01:00 6 200 2023-05-06 18:01:00 2023-05-06 18:01:00 | ||
|
||
statement ok | ||
insert into t values | ||
('2023-05-06 18:08:00', 7, 100) | ||
, ('2023-05-06 18:10:00', 9, 200) | ||
; | ||
|
||
query TiiTT | ||
select * from v1 order by tm; | ||
---- | ||
2023-05-06 16:51:00 1 100 2023-05-06 16:51:00 2023-05-06 16:56:00 | ||
2023-05-06 16:56:00 8 100 2023-05-06 16:51:00 2023-05-06 16:56:00 | ||
2023-05-06 17:30:00 3 200 2023-05-06 17:30:00 2023-05-06 17:30:00 | ||
2023-05-06 17:35:00 5 100 2023-05-06 17:35:00 2023-05-06 17:35:00 | ||
2023-05-06 17:59:00 4 100 2023-05-06 17:59:00 2023-05-06 18:08:00 | ||
2023-05-06 18:01:00 6 200 2023-05-06 18:01:00 2023-05-06 18:10:00 | ||
2023-05-06 18:08:00 7 100 2023-05-06 17:59:00 2023-05-06 18:08:00 | ||
2023-05-06 18:10:00 9 200 2023-05-06 18:01:00 2023-05-06 18:10:00 | ||
|
||
statement ok | ||
drop view v1; | ||
|
||
statement ok | ||
drop table t; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
{"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://example.com/product.schema.json","title":"Product","description":"A product from Acme's catalog","type":"object","properties":{"productId":{"description":"The unique identifier for a product","type":"integer"},"productName":{"description":"Name of the product","type":"string"},"price":{"description":"The price of the product","type":"number","exclusiveMinimum":0},"tags":{"description":"Tags for the product","type":"array","items":{"type":"string"},"minItems":1,"uniqueItems":true},"dimensions":{"type":"object","properties":{"length":{"type":"number"},"width":{"type":"number"},"height":{"type":"number"}},"required":["length","width","height"]}},"required":["productId","productName","price"]} | ||
{"productId":1,"productName":"An ice sculpture","price":12.5,"tags":["cold","ice"],"dimensions":{"length":7,"width":12,"height":9.5}} | ||
{"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://example.com/product.schema.json","title":"Product","description":"A product from Acme's catalog","type":"object","properties":{"productId":{"description":"The unique identifier for a product","type":"integer"},"productName":{"description":"Name of the product","type":"string"},"price":{"description":"The price of the product","type":"number","exclusiveMinimum":0},"tags":{"description":"Tags for the product","type":"array","items":{"type":"string"},"minItems":1,"uniqueItems":true},"dimensions":{"type":"object","properties":{"length":{"type":"number"},"width":{"type":"number"},"height":{"type":"number"}},"required":["length","width","height"]},"map":{"type":"object","additionalProperties":{"type":"string"}},"notMap":{"type":"object","additionalProperties":{"type":"string"},"properties":{"a":{"type":"string"}}}},"required":["productId","productName","price"]} | ||
{"productId":1,"productName":"An ice sculpture","price":12.5,"tags":["cold","ice"],"dimensions":{"length":7,"width":12,"height":9.5},"map":{"foo":"bar"},"notMap":{"a":"b","ignored":"c"}} |
Oops, something went wrong.