Skip to content

Commit 297ece7

Browse files
committed
add info_schema query
1 parent e7ef10f commit 297ece7

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

enginetest/queries/information_schema_queries.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ var InfoSchemaQueries = []QueryTest{
3030
Query: "SHOW KEYS FROM `columns` FROM `information_schema`;",
3131
Expected: []sql.Row{},
3232
},
33+
{
34+
Query: "SELECT table_schema AS TABLE_CAT, NULL AS TABLE_SCHEM, table_name, CASE WHEN table_type = 'BASE TABLE' THEN CASE WHEN table_schema = 'mysql' OR table_schema = 'performance_schema' THEN 'SYSTEM TABLE' ELSE 'TABLE' END WHEN table_type = 'TEMPORARY' THEN 'LOCAL_TEMPORARY' ELSE table_type END AS TABLE_TYPE FROM information_schema.tables; ",
35+
Expected: []sql.Row{{"information_schema", nil, "administrable_role_authorizations", "SYSTEM VIEW"}},
36+
},
3337
{
3438
Query: `SELECT
3539
table_name, index_name, comment, non_unique, GROUP_CONCAT(column_name ORDER BY seq_in_index) AS COLUMNS

0 commit comments

Comments
 (0)