Use show schemas
instead of selecting from information_schema.schemata on Snowflake
#2166
Labels
show schemas
instead of selecting from information_schema.schemata on Snowflake
#2166
Describe the feature
Background:
Let's replace the call to
information_schema.schemata
on Snowflake with a call toshow schemas in <database>
.Advantages:
show schemas
will not queue, whereas theselect
statement can queueshow schemas
does not require a running warehouseshow schemas
appears to be strictly faster than the information_schema alternativeWe should consider applying this approach for other queries, as described in #1877 (the key benefit being that these queries do not queue. Let's keep #1877 open and tackle these other queries separately. See also #2157
Disadvantages:
show schemas
requires the database name to be cased and quoted appropriately. I actually think this is the same behavior as selecting fromdatabase.information_schema.<table>
, so that might not be an issue here?The text was updated successfully, but these errors were encountered: