Manage listings with SQL as a provider - examples¶
The following are examples of the common tasks that providers can complete programmatically with SQL commands:
Create a draft private listing ready for sharing with another account¶
Create a draft listing which is automatically replicated to other regions.
This example is identical to Share data with another Snowflake account but creates a draft listing. For a complete description of all combinations of the REVIEW and PUBLISH properties, and their meanings, see CREATE LISTING.
Description |
Notes |
---|---|
Create a replicated private listing. |
Replicate the listing and refresh every 10 minutes. Do not submit the listing for approval ( Do not publish ( |
CREATE EXTERNAL LISTING DRAFT_PRIVATE_REPLICATED
SHARE MySHARE AS
$$
title: "weather data"
description: "Listing containing weather data for all zipcodes in America"
listing_terms:
type: “OFFLINE”
targets:
accounts: [“targetorg.targetaccount”]
auto_fulfillment:
refresh_type: SUB_DATABASE
refresh_schedule: '10 MINUTE'
$$ PUBLISH=FALSE REVIEW=FALSE;