Schema:
ACCOUNT_USAGE

DATABASE_STORAGE_USAGE_HISTORY View

This Account Usage view can be used to query the average daily storage usage, in bytes, for databases in the account for the last 365 days (1 year). The data includes:

  • All data stored in tables in the database(s).
  • All historical data maintained in Fail-safe for the database(s).

Columns

Column Name Data Type Description
USAGE_DATE DATE Date of this storage usage record.
DATABASE_ID NUMBER Internal/system-generated identifier for the database.
DATABASE_NAME TEXT Name of the database.
DELETED TIMESTAMP_LTZ Date and time when the database was dropped; NULL for active databases.
AVERAGE_DATABASE_BYTES FLOAT Number of bytes of database storage used, including data in Time Travel.
AVERAGE_FAILSAFE_BYTES FLOAT Number of bytes of Fail-safe storage used.

Usage Notes

  • Latency for the view may be up to 180 minutes (3 hours).