Schema:

DATA_SHARING_USAGE

APPLICATION_STATE view

This view in the DATA_SHARING_USAGE schema can be used to display information about apps installed from a listing for all application packages in the current account.

If a listing was published using Cross-Cloud Auto-Fulfillment, this view displays information for installed apps across all regions.

Columns

Column NameData TypeDescription
CONSUMER_SNOWFLAKE_REGIONVARCHARThe Snowflake region of the consumer account where the app is installed.
CONSUMER_ORGANIZATION_NAMEVARCHARThe organization name of the consumer account.
CONSUMER_ACCOUNT_LOCATORVARCHARThe consumer account locator.
CONSUMER_ACCOUNT_NAMEVARCHARThe consumer account name.
PROVIDER_SNOWFLAKE_REGIONVARCHARThe Snowflake region of the provider account that created the application package.
PROVIDER_ACCOUNT_LOCATORVARCHARThe provider account locator.
PROVIDER_ACCOUNT_NAMEVARCHARThe provider account name.
PACKAGE_NAMEVARCHAR

The current name for the application package in the provider’s account from which the app was installed.

APPLICATION_NAME_HASHVARCHAR

The hash string of the name of the installed app instance in the consumer account. The consumer uses the SYSTEM$GET_HASH_FOR_APPLICATION function to calculate the hash value of the installed application. The consumer can then use this value when contacting the provider.

CREATED_ONDATETIMEThe timestamp when the app instance was first installed.
CURRENT_VERSIONVARCHARThe current version of the app.
CURRENT_PATCHINTThe current patch level of the app.
CURRENT_INSTALLED_ONDATETIMEThe timestamp when the current version of the app was installed.
PREVIOUS_VERSION_STATEVARCHAR

The state of the previous version. Possible values are COMPLETE and FINALIZING.

  • COMPLETE indicates that upgrade is completed and that there are no active queries being executed from the previous version, if it exists.
  • FINALIZING indicates that the instance has been upgraded from the previous version, however one or more queries may be still be running that are using the previous version.
PREVIOUS_VERSIONVARCHARThe previous version of the app.
PREVIOUS_PATCHINTThe previous patch level of the app.
UPGRADE_STATEVARCHARThe version upgrade state of the app. See Application version upgrade states for more information.
TARGET_UPGRADE_VERSIONVARCHARThe target version of the app that is running or pending upgrade.
TARGET_UPGRADE_PATCHINTThe version patch level of the app that is running or pending upgrade.
UPGRADE_STARTED_ONDATETIMEThe timestamp when the app upgrade started.
UPGRADE_ATTEMPTINTThe number of attempts to upgrade to the target version or patch.
UPGRADE_ATTEMPTED_ONDATETIMEThe timestamp when the most recent upgrade attempt was attempted.
UPGRADE_FAILURE_REASONVARCHARA description of the failure if the previous app upgrade failed.
LISTING_NAMEVARCHARThe name of the listing on the data exchange from which the app was installed.
LISTING_DISPLAY_NAMEVARCHARThe display name of the listing.
EXCHANGE_NAMEVARCHARThe data exchange name of the listing from which the app was installed.
LAST_HEALTH_STATUSVARCHAR

The last reported health status of the app. Possible values are:

  • OK
  • FAILED
  • PAUSED
LAST_HEALTH_STATUS_UPDATED_ONVARCHARThe timestamp when the health status was last reported.
ENABLED_TELEMETRY_EVENT_DEFINITIONSVARCHAR

A list of event definitions that the consumer has enabled. See About event definitions for more information.

UPGRADE_STATE_UPDATED_ONTIMESTAMP_LTZ

The timestamp when the app entered its current upgrade state. This value is automatically set by Snowflake.

DISABLEMENT_REASONSVARCHARAn array containing the reasons why the Snowflake Native App was disabled. See Reasons an app can become disabled.

Reasons an app can become disabled

The following table lists the possible values for the DISABLEMENT_REASONS column:

ValueStatus descriptionIs recoverable?
MANUALLY_DISABLEDThe app is disabled by SnowflakeYes. To re-enable the app, contact Snowflake Support.
ACCOUNT_INACTIVE

The account becomes inactive by being locked or suspended causing the app to be unavailable. In this state a consumer cannot execute any SQL queries in their account and the app cannot be upgraded.

Yes. The app is automatically re-enabled if the account lock or suspension is removed
PACKAGE_VERSION_IS_MISSINGThe application package version for the app was dropped by the provider.

Possibly. This can be caused by a temporary platform outage, in which case the app may recover automatically. Otherwise, the provider can work with Snowflake Support to attempt version recovery. Contact the application provider for more details.

CMK_ACCESS_DENIED

The consumer manages the encryption key themselves (ENCRYPT_USE_CMK_KMS is enabled) and Snowflake doesn’t have access to this key.

Yes. To re-enable the app, ensure that the cloud provider configuration to retrieve the CMK is correct and that Snowflake has access to the key.

LISTING_ACCESS_REVOKED

The listing used to create the app is no longer available. Possible reasons for this status include:

  • The provider deleted the listing
  • The provider manually removed access to the private listing from the consumer account

Possibly. Recoverability depends on the reason why access was revoked.

For example, if the listing was deleted it is not recoverable. If a consumer account was manually removed from the private listing, access to the listing and app can be restored.

LISTING_TRIAL_USAGE_EXCEEDEDThe application has exceeded the usage limit for a usage-based trial listing.No
LISTING_PAYMENT_REQUIRED

The listing used to install the app is a paid listing and requires payment for further usage.

Yes. The consumer must correctly set up payment for the app.
LISTING_TRIAL_TIME_EXCEEDEDThe application exceeded the trial duration.No
APPLICATION_PACKAGE_NOT_AVAILABLE

The application package used to create the app no longer exists. The provider may have dropped the corresponding application package.

No
APPLICATION_PACKAGE_DISABLEDThe application package used to create the app is disabled by the Snowflake.Yes. The app is re-enabled, if Snowflake re-enables the application package.
APPLICATION_SUSPENDED

The app resources for example, tasks, services, and compute pools, are suspended due to the app being disabled.

The suspended objects remain suspended until the app is re-enabled and there are no other reasons the app was disabled.

Yes
APPLICATION_SUSPEND_RESUME_IN_PROGRESSThe app resources, for example tasks, services, and compute pools, are currently resuming.Yes

Application version upgrade states

The following are the possible values for the UPGRADE_STATE column:

  • INSTALLING: The application object is in the process of being created.
  • INSTALL_FAILED: The creation of the application object failed. The application object remains in the INSTALL_FAILED state until it is dropped. See the UPGRADE_FAILURE_REASON column of the DESCRIBE APPLICATION command for information about why the installation or upgrade failed.
  • COMPLETE: The setup script successfully completed and the application object was created or upgraded.
  • QUEUED: The application object is queued for upgrade.
  • UPGRADING: The application object is in the process of being upgraded.
  • FAILED: All upgrade attempts failed. The reason for the failure is listed in the UPGRADE_FAILURE_REASON column, if present. The instance remains in the FAILED state until a release directive is updated to point to a different version than the one that the upgrade was targeting, as defined in the TARGET_UPGRADE_VERSION column.
  • QUEUED_DELAYED: The application object is queued for an upgrade that is scheduled for a future time.
  • QUEUED_RETRY: The instance failed one or more upgrade attempts. The reason for the failure is indicated in UPGRADE_FAILURE_REASON: The instance is queued to perform another upgrade attempt.
  • DISABLED: The application object and its upgrades were disabled. In this state the instance will be inaccessible for consumers, it will not be considered for upgrades and will not block application package version drop. The reason for the failure is listed in the UPGRADE_FAILURE_REASON column, if present.

Usage notes

  • There is no data retention for this view. If an app is uninstalled the information contained in this view is no longer available.