/plushcap/analysis/metaplane/metaplane-three-ways-to-retrieve-row-counts-for-snowflake-tables-and-views

Three Ways to Retrieve Row Counts for Snowflake Tables and Views

What's this blog post about?

This article discusses three methods to retrieve row counts for Snowflake tables and views: using the `COUNT(*)` function, leveraging table statistics, and querying metadata or information schema. The first method is straightforward but can be resource-intensive for large tables. The second method provides approximate row counts based on table statistics, while the third method allows efficient retrieval of exact row counts for tables only. Each method has its pros and cons, and users should choose the most suitable one based on their specific requirements.

Company
Metaplane

Date published
May 12, 2023

Author(s)
Kevin HuPhD

Word count
481

Language
English

Hacker News points
None found.


By Matt Makai. 2021-2024.