-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
209 additions
and
92 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
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,8 +1,7 @@ | ||
# F031-02: CREATE VIEW statement | ||
|
||
# TODO: Support `VIEW` | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F031_02_01_01 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F031_02_01_01 AS SELECT A FROM TABLE_F031_02_01_01 | ||
statement ok | ||
CREATE VIEW VIEW_F031_02_01_01 AS SELECT A FROM TABLE_F031_02_01_01 |
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,10 +1,11 @@ | ||
# F031-16: DROP VIEW statement: RESTRICT clause | ||
|
||
# TODO: Support `VIEW` & `CREATE VIEW` & `DROP VIEW` | ||
# TODO: Support `DROP VIEW` | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F031_16_01_01 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F031_16_01_01 AS SELECT A FROM TABLE_F031_16_01_01; | ||
statement ok | ||
CREATE VIEW VIEW_F031_16_01_01 AS SELECT A FROM TABLE_F031_16_01_01; | ||
|
||
# DROP VIEW VIEW_F031_16_01_01 |
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,45 +1,55 @@ | ||
# F131-01: WHERE, GROUP BY, and HAVING clauses supported in queries with grouped views | ||
|
||
# TODO: WHERE, GROUP BY, and HAVING clauses supported in queries with grouped views | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_01_01_01 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_01_01_01 AS SELECT A FROM TABLE_F131_01_01_01 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_01_01_01 AS SELECT A FROM TABLE_F131_01_01_01 GROUP BY A; | ||
|
||
# SELECT A FROM VIEW_F131_01_01_01 | ||
query I | ||
SELECT A FROM VIEW_F131_01_01_01 | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_01_01_02 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_01_01_02 AS SELECT A FROM TABLE_F131_01_01_02 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_01_01_02 AS SELECT A FROM TABLE_F131_01_01_02 GROUP BY A; | ||
|
||
# SELECT A FROM VIEW_F131_01_01_02 GROUP BY A | ||
query I | ||
SELECT A FROM VIEW_F131_01_01_02 GROUP BY A | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_01_01_03 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_01_01_03 AS SELECT A FROM TABLE_F131_01_01_03 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_01_01_03 AS SELECT A FROM TABLE_F131_01_01_03 GROUP BY A; | ||
|
||
# SELECT A FROM VIEW_F131_01_01_03 GROUP BY A HAVING A = 2 | ||
query I | ||
SELECT A FROM VIEW_F131_01_01_03 GROUP BY A HAVING A = 2 | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_01_01_04 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_01_01_04 AS SELECT A FROM TABLE_F131_01_01_04 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_01_01_04 AS SELECT A FROM TABLE_F131_01_01_04 GROUP BY A; | ||
|
||
# SELECT A FROM VIEW_F131_01_01_04 WHERE A = 1 | ||
query I | ||
SELECT A FROM VIEW_F131_01_01_04 WHERE A = 1 | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_01_01_05 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_01_01_05 AS SELECT A FROM TABLE_F131_01_01_05 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_01_01_05 AS SELECT A FROM TABLE_F131_01_01_05 GROUP BY A; | ||
|
||
# SELECT A FROM VIEW_F131_01_01_05 WHERE A = 1 GROUP BY A | ||
query I | ||
SELECT A FROM VIEW_F131_01_01_05 WHERE A = 1 GROUP BY A | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_01_01_06 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_01_01_06 AS SELECT A FROM TABLE_F131_01_01_06 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_01_01_06 AS SELECT A FROM TABLE_F131_01_01_06 GROUP BY A; | ||
|
||
# SELECT A FROM VIEW_F131_01_01_06 WHERE A = 1 GROUP BY A HAVING A = 2 | ||
query I | ||
SELECT A FROM VIEW_F131_01_01_06 WHERE A = 1 GROUP BY A HAVING A = 2 |
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,13 +1,13 @@ | ||
# F131-02: Multiple tables supported in queries with grouped views | ||
|
||
# TODO Multiple tables supported in queries with grouped views | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_02_01_011 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_02_01_012 ( ID INT PRIMARY KEY, A INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_02_01_01 AS SELECT A FROM TABLE_F131_02_01_011 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_02_01_01 AS SELECT A FROM TABLE_F131_02_01_011 GROUP BY A; | ||
|
||
# SELECT A FROM VIEW_F131_02_01_01 JOIN TABLE_F131_02_01_012 USING ( A ) | ||
query I | ||
SELECT A FROM VIEW_F131_02_01_01 JOIN TABLE_F131_02_01_012 USING ( A ) |
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,17 +1,22 @@ | ||
# F131-03: Set functions supported in queries with grouped views | ||
|
||
# TODO: Set functions supported in queries with grouped views | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_03_01_011 ( ID INT PRIMARY KEY, A INTEGER, B INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_03_01_01 AS SELECT A, MIN ( B ) AS C FROM TABLE_F131_03_01_011 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_03_01_01 AS SELECT A, MIN ( B ) AS C FROM TABLE_F131_03_01_011 GROUP BY A; | ||
|
||
# SELECT SUM ( C ) FROM VIEW_F131_03_01_01 | ||
query I | ||
SELECT SUM ( C ) FROM VIEW_F131_03_01_01 | ||
---- | ||
null | ||
|
||
statement ok | ||
CREATE TABLE TABLE_F131_03_01_021 ( ID INT PRIMARY KEY, A INTEGER, B INTEGER ); | ||
|
||
# CREATE VIEW VIEW_F131_03_01_02 AS SELECT A, MIN ( B ) AS C FROM TABLE_F131_03_01_021 GROUP BY A; | ||
statement ok | ||
CREATE VIEW VIEW_F131_03_01_02 AS SELECT A, MIN ( B ) AS C FROM TABLE_F131_03_01_021 GROUP BY A; | ||
|
||
# SELECT SUM ( C ) FROM VIEW_F131_03_01_02 GROUP BY A | ||
query I | ||
SELECT A, SUM ( C ) FROM VIEW_F131_03_01_02 GROUP BY A | ||
---- |
Oops, something went wrong.