Skip to content

Commit

Permalink
fix e2e test
Browse files Browse the repository at this point in the history
  • Loading branch information
zwang28 committed May 19, 2023
1 parent 4a5ca23 commit f3823ae
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 21 deletions.
40 changes: 20 additions & 20 deletions e2e_test/batch/aggregate/jsonb_agg.slt.part
Original file line number Diff line number Diff line change
Expand Up @@ -12,44 +12,44 @@ insert into t values
(true, 3, 'aaa', '{}');

query T
select jsonb_agg(v1) from t;
select jsonb_agg(v1 order by v1) from t;
----
[null, false, true, true]
[false, true, true, null]

query T
select jsonb_agg(v2) from t;
select jsonb_agg(v2 order by v2) from t;
----
[null, 1, 2, 3]
[1, 2, 3, null]

query T
select jsonb_agg(v2::int2) from t;
select jsonb_agg(v2::int2 order by v2) from t;
----
[null, 1, 2, 3]
[1, 2, 3, null]

query T
select jsonb_agg(v2::int8) from t;
select jsonb_agg(v2::int8 order by v2) from t;
----
[null, 1, 2, 3]
[1, 2, 3, null]

query T
select jsonb_agg(v2::float4) from t;
select jsonb_agg(v2::float4 order by v2) from t;
----
[null, 1.0, 2.0, 3.0]
[1.0, 2.0, 3.0, null]

query T
select jsonb_agg(v2::float8) from t;
select jsonb_agg(v2::float8 order by v2) from t;
----
[null, 1.0, 2.0, 3.0]
[1.0, 2.0, 3.0, null]

query T
select jsonb_agg(v3) from t;
select jsonb_agg(v3 order by v3) from t;
----
[null, "ccc", "bbb", "aaa"]
["aaa", "bbb", "ccc", null]

query T
select jsonb_agg(v4) from t;
select jsonb_agg(v4 order by v4) from t;
----
[null, null, false, {}]
[false, null, {}, null]

# query T
# select jsonb_agg(distinct v1) from t;
Expand All @@ -62,25 +62,25 @@ select jsonb_agg(v2 order by v3 desc) from t;
[null, 1, 2, 3]

query T
select jsonb_agg(v2) filter (where v3 >= 'bbb') from t;
select jsonb_agg(v2 order by v2) filter (where v3 >= 'bbb') from t;
----
[1, 2]

statement error field name must not be null
select jsonb_object_agg(v3, v1) from t;

query T
select jsonb_object_agg(v3, v1) filter (where v3 is not null) from t;
select jsonb_object_agg(v3, v1 order by v3, v1) filter (where v3 is not null) from t;
----
{"aaa": true, "bbb": true, "ccc": false}

query T
select jsonb_object_agg(v3, v2) filter (where v3 is not null) from t;
select jsonb_object_agg(v3, v2 order by v3, v2) filter (where v3 is not null) from t;
----
{"aaa": 3, "bbb": 2, "ccc": 1}

query T
select jsonb_object_agg(v3, v4) filter (where v3 is not null) from t;
select jsonb_object_agg(v3, v4 order by v3, v4) filter (where v3 is not null) from t;
----
{"aaa": {}, "bbb": false, "ccc": null}

Expand Down
2 changes: 1 addition & 1 deletion e2e_test/batch/basic/table_with_default_columns.slt.part
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ statement ok
insert into t2 values (1), (2);

query II
select * from t2;
select * from t2 order by v1;
----
1 2
2 2
Expand Down

0 comments on commit f3823ae

Please sign in to comment.