Skip to content

Commit

Permalink
fix(sqlness): enforce order in union tests (#5190)
Browse files Browse the repository at this point in the history
Add ORDER BY clause to subquery union tests

 Updated the SQL and result files for subquery union tests to include an ORDER BY clause, ensuring consistent result ordering. This change aligns with the test case from the DuckDB repository.
  • Loading branch information
v0y4g3r authored Dec 18, 2024
1 parent 9b4e855 commit fa773cf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/cases/standalone/common/subquery/table.result
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ Affected Rows: 0

-- subquery union, from:
-- https://github.com/duckdb/duckdb/blob/9196dd9b0a163e6c8aada26218803d04be30c562/test/sql/subquery/table/test_subquery_union.test
SELECT * FROM (SELECT 42) UNION ALL SELECT * FROM (SELECT 43);
SELECT * FROM (SELECT 42) UNION ALL SELECT * FROM (SELECT 43) ORDER BY 1;

+-----------+
| Int64(42) |
Expand Down
2 changes: 1 addition & 1 deletion tests/cases/standalone/common/subquery/table.sql
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ DROP TABLE test;

-- subquery union, from:
-- https://github.com/duckdb/duckdb/blob/9196dd9b0a163e6c8aada26218803d04be30c562/test/sql/subquery/table/test_subquery_union.test
SELECT * FROM (SELECT 42) UNION ALL SELECT * FROM (SELECT 43);
SELECT * FROM (SELECT 42) UNION ALL SELECT * FROM (SELECT 43) ORDER BY 1;

-- table subquery, from:
-- https://github.com/duckdb/duckdb/blob/8704c7d0807d6ce1e2ebcdf6398e1b6cc050e507/test/sql/subquery/table/test_table_subquery.test
Expand Down

0 comments on commit fa773cf

Please sign in to comment.