'How to get row count of VIEW table along with Metadata information in Snowflake?
I would like to get row count of VIEW table in Snowflake along with metadata information such as TABLE_SCHEMA,TABLE_NAME,CREATED,LAST_ALTERED columns from INFORMATION_SCHEMA for the specific VIEW table.Let say my VIEW table name is "V_TEST"
I can write SELECT COUNT(*) FROM DB.SCHEMA.V_TEST and get a row count for VIEW table but not sure how to merge in the table with metadata table ?
I can get TABLE_SCHEMA,TABLE_NAME,CREATED,LAST_CREATED using below code
SELECT TABLE_SCHEMA,TABLE_NAME,CREATED,LAST_CREATED FROM DB.Information_SCHEMA.VIEWS
WHERE TABLE_NAME='V_TEST'
Thanks in advance for your help and efforts!
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
