Schema:

ORGANIZATION_USAGE

For guidance on query performance when using organization-wide usage views, see Performance (Organization Usage).

PIPES view

Important

This view is only available in the organization account. For more information, see Premium views in the organization account.

Organization Usage performance

When you query a specific view in the SNOWFLAKE.ORGANIZATION_USAGE schema, follow the organization-wide guidance in Performance (Organization Usage): bound every scan on history views, list columns explicitly, and use the time filter column table plus worked SQL and anti-patterns there.

This Organization Usage view displays a row for each pipe defined in an account.

Columns

Organization-level columns

Column NameData TypeDescription
ORGANIZATION_NAMEVARCHARName of the organization.
ACCOUNT_LOCATORVARCHARSystem-generated identifier for the account.
ACCOUNT_NAMEVARCHARUser-defined identifier for the account.

Additional columns

Column NameData TypeDescription
PIPE_IDNUMBERInternal or system-generated identifier for the pipe.
PIPE_NAMEVARCHAR“The name of the pipe object.
For manually created pipes, this is the name defined in the CREATE PIPE statement.
For the Snowpipe Streaming high-performance default pipe, this is derived from the target table name; for example, MY_TABLE-STREAMING.”
PIPE_SCHEMA_IDNUMBER“Internal or system-generated identifier for the schema that the pipe belongs to.
For the default pipe, this corresponds to the target table’s schema ID.”
PIPE_SCHEMAVARCHAR“Schema that the pipe belongs to.
For the default pipe, this corresponds to the target table’s schema.”
PIPE_CATALOG_IDNUMBER“Internal or system-generated identifier for the database that the pipe belongs to.
For the default pipe, this corresponds to the target table’s database ID.”
PIPE_CATALOGVARCHAR“Name of the database that the pipe belongs to.
For the default pipe, this corresponds to the target table’s database.”
IS_AUTOINGEST_ENABLEDVARCHARWhether AUTO-INGEST is enabled for the pipe. Represents future functionality.
NOTIFICATION_CHANNEL_NAMEVARCHARAmazon Resource Name of the Amazon SQS queue for the stage named in the DEFINITION column. Represents future functionality.
PIPE_OWNERVARCHAR“Name of the role that owns the pipe.
Returns NULL for the default pipe.”
DEFINITIONVARCHARCOPY statement used to load data from queued files into a Snowflake table.
CREATEDTIMESTAMP_LTZCreation time of the pipe.
LAST_ALTEREDTIMESTAMP_LTZDate and time the object was last altered by a DML, DDL, or background metadata operation. See Usage Notes.
COMMENTVARCHAR“Comment for this pipe.
Returns the following message for the default pipe: “”Default pipe for Snowpipe Streaming High Performance ingestion to a table. Created and managed by Snowflake.”””
PATTERNVARCHARPATTERN copy option value in the COPY INTO <table> statement in the pipe definition, if the copy option was specified.
DELETEDTIMESTAMP_LTZDate and time when the pipe was deleted.
OWNER_ROLE_TYPEVARCHAR“The type of role that owns the object; for example, ROLE.
If a Snowflake Native App owns the object, the value is APPLICATION.
Snowflake returns NULL if you delete the object because a deleted object doesn’t have an owner role.
Returns NULL for the default pipe.”

Usage notes

  • Latency for the view may be up to 24 hours.
  • The view only displays objects for which the current role for the session has been granted access privileges.
  • The view does not recognize the MANAGE GRANTS privilege and consequently may show less information compared to a SHOW command executed by a user who holds the MANAGE GRANTS privilege.
  • The LAST_ALTERED column is updated when the following operations are performed on an object:

    • DDL operations.
    • DML operations (for tables only). This column is updated even when no rows are affected by the DML statement.
    • Background maintenance operations on metadata performed by Snowflake.

Examples

The following example joins this view with PIPE_USAGE_HISTORY view on the PIPE_ID column to track the credit usage associated with each unique PIPE object:

select a.PIPE_CATALOG as PIPE_CATALOG,
       a.PIPE_SCHEMA as PIPE_SCHEMA,
       a.PIPE_NAME as PIPE_NAME,
       b.CREDITS_USED as CREDITS_USED
from SNOWFLAKE.ORGANIZATION_USAGE.PIPES a join SNOWFLAKE.ORGANIZATION_USAGE.PIPE_USAGE_HISTORY b
on a.pipe_id = b.pipe_id
where b.START_TIME > date_trunc(month, current_date);