id
stringlengths
16
145
text
stringlengths
1
179k
title
stringclasses
1 value
snowflake_docs/factorial_0_0.txt
/ 1. Arithmetic 4. Rounding and Truncation 13. Exponent and Root 21. Logarithmic 24. Trigonometric 42. Other numeric) FACTORIAL Categories:
snowflake_docs/match_recognize_13_0.txt
AFTER MATCH SKIP: Specifying Where to Continue After a Match ¶ AFTER MATCH SKIP { PAST LAST ROW | TO NEXT ROW | TO [ { FIRST | LAST} ] <symbol> } Copy This subclause specifies where to continue the matching after a positive match was found. * ` PAST LAST ROW (default) ` ...
snowflake_docs/copy-files_2_0.txt
label-data-load-overview-internal-stages)
snowflake_docs/system_global_account_set_parameter_2_0.txt
label-intro-to-client-redirect) .
snowflake_docs/regr_intercept_3_0.txt
Arguments ¶ ` _ y _ ` The dependent variable. This must be an expression that can be evaluated to a numeric type. ` _ x _ ` The independent variable. This must be an expression that can be evaluated to a numeric type. ` _ expr3 _ ` This is the optional expression used to group rows into partitions. Important Note...
snowflake_docs/h3_get_resolution_2_0.txt
Syntax ¶ H3_GET_RESOLUTION( <cell_id> ) Copy
snowflake_docs/drop-database_3_0.txt
Parameters ¶ ` _ name _ ` Specifies the identifier for the database to drop. If the identifier contains spaces, special characters, or mixed-case characters, the entire string must be enclosed in double quotes. Identifiers enclosed in double quotes are also case-sensitive. ` CASCADE | RESTRICT ` Specifies whethe...
snowflake_docs/comment_0_0.txt
/
snowflake_docs/st_geogfromgeohash_4_0.txt
Returns ¶ geospatial.html
snowflake_docs/access_history_0_0.txt
/ Schema:
snowflake_docs/approx_top_k_combine_2_0.txt
Syntax ¶ APPROX_TOP_K_COMBINE( <state> [ , <counters> ] ) Copy
snowflake_docs/drop-sequence_3_0.txt
Parameters ¶ ` _ name _ ` Specifies the identifier of the sequence to drop. If the sequence identifier is not fully-qualified (in the form of ` _ db_name _ . _ schema_name _ . _ sequence_name _ ` or ` _ schema_name _ . _ sequence_name _ ` ), the command looks for the sequence in the current schema for the se...
snowflake_docs/sql-all_7_1.txt
w to create constraints by specifying a ` CONSTRAINT ` table) statement. | Creates a new tag or replaces an existing tag in the system. | Creates a new task in the current/specified schema or replaces an existing task. | Creates a new user or replaces an existing user in the system. | Creates a new versioned s...
snowflake_docs/get_config_0_0.txt
/ 1. Commands 4. Methods
snowflake_docs/alter-security-integration-api-auth_9_0.txt
label-security-custom-role) . For general information about roles and privilege grants for performing SQL overview.html
snowflake_docs/system_get_classification_result_4_0.txt
Returns ¶ Returns a JSON object in the following format. For example: { "classification_result": { "col1_name": { "alternates": [], "recommendation": { "confidence": "HIGH", "coverage": 1, "details": [ { "coverage...
snowflake_docs/desc-service_7_0.txt
Access control requirements ¶ access-control-overview-roles) used to execute this SQL command must have the overview.html
snowflake_docs/create-share_10_0.txt
Examples ¶ Create an empty share named ` sales_s ` : > > CREATE SHARE sales_s; > > > Copy > > > +-----------------------------------------+ > | status | > |-----------------------------------------| > | Share SALES_S successfully created. | > +-----...
snowflake_docs/map_delete_1_0.txt
MAP_DELETE ¶ available to all accounts. or more keys removed..
snowflake_docs/show-dynamic-tables_2_0.txt
Syntax ¶ SHOW DYNAMIC TABLES [ LIKE '<pattern>' ] [ IN { ACCOUNT | DATABASE | DATABASE <db_name> | SCHEMA ...
snowflake_docs/system_abort_session_3_0.txt
Arguments ¶ ` _ session_id _ ` Identifier for the session to abort. To obtain the ID for a session, log into the web interface as an account administrator (user with the ACCOUNTADMIN role) and go to:
snowflake_docs/alter-security-integration-saml2_6_0.txt
label-account-locator) , so if you define a different [ URL url) in the IdP, make sure to set this property appropriately. ` SAML2_SNOWFLAKE_ACS_URL = '<string_literal>' ` The string containing the Snowflake Assertion Consumer Service URL to which the IdP will send its SAML authentication response back to Snowflake....
snowflake_docs/show-failover-groups_7_0.txt
label-region-groups) . ` snowflake_region ` | Snowflake Region where the account is located. A Snowflake Region is a distinct location within a cloud platform region that is isolated from other Snowflake Regions. A Snowflake Region can be either multi-tenant or single- tenant (for a Virtual Private Snowflake account...
snowflake_docs/raise_4_0.txt
Examples ¶ This creates and raises (but does not catch) a simple exception: CREATE PROCEDURE thrower() RETURNS VARCHAR LANGUAGE SQL AS $$ DECLARE MY_EXCEPTION EXCEPTION; BEGIN RAISE MY_EXCEPTION; END; $$ ; Copy Here is the call to the stored...
snowflake_docs/create-function_36_0.txt
label-access-control-securable-objects) , see [ Overview of
snowflake_docs/regexp_instr_6_0.txt
Collation Details ¶ Arguments with collation specifications are currently not supported.
snowflake_docs/procedures_2_0.txt
Columns ¶ Column Name | Data Type | Description ---|---|--- PROCEDURE_CATALOG | TEXT | Database which the stored procedure belongs to PROCEDURE_SCHEMA | TEXT | Schema which the stored procedure belongs to PROCEDURE_NAME | TEXT | Name of the stored procedure PROCEDURE_OWNER | TEXT | Name of the role that ow...
snowflake_docs/create-security-integration-scim_4_0.txt
Optional parameters ¶ ` NETWORK_POLICY = ' _ network_policy _ ' ` that controls SCIM network traffic. If there are also network policies set for the account or user, see [ Network policy-precedence) . ` SYNC_PASSWORD = { TRUE | FALSE } ` Specifies whether to enable or disable the synchronization of a use...
snowflake_docs/tan_1_0.txt
TAN ¶ Computes the tangent of its argument; the argument should be expressed in radians.
snowflake_docs/parameters_93_0.txt
TIMESTAMP_INPUT_FORMAT ¶ Type : Session — Can be set for Account » User » Session Data Type : String Description : Specifies the input format for the TIMESTAMP data type alias. For more output) . Values : Any valid, supported timestamp format or ` AUTO ` ( ` AUTO ` specifies that Snowflake attempts to automati...
snowflake_docs/ascii_4_0.txt
Returns ¶ The value is an integer that is the numeric representation of the ASCII character. For example, if the input is the letter ‘a’, then the return value is 97.
snowflake_docs/get_stage_location_2_0.txt
Syntax ¶ GET_STAGE_LOCATION( @<stage_name> ) Copy
snowflake_docs/uuid_string_4_0.txt
Examples ¶ SELECT UUID_STRING(); +--------------------------------------+ | UUID_STRING() | |--------------------------------------| | 3afd051d-4bd0-4b30-8376-cf062719f090 | +--------------------------------------+ Copy SELECT UUID_STRING('fe971b24-9572-4005-b22f-35...
snowflake_docs/localtimestamp_3_0.txt
Arguments ¶ ` _ fract_sec_precision _ ` This optional argument indicates the precision with which to report the time. For example, a value of 3 says to use 3 digits after the decimal point (i.e. to specify the time with a precision of milliseconds). The default precision is 9 (nanoseconds). Valid values range from ...
snowflake_docs/desc-user_0_0.txt
/ 1. User Management 7. Database Role Management 16. Account-level Role Management 25. Privilege Management DESCRIBE USER
snowflake_docs/asof-join_14_0.txt
Less Than and Greater Than Comparison Operators ¶ Following on from the previous example, two ASOF joins are specified, but this time the first match condition uses the ` > ` operator and the second uses the ` < ` operator. The result is a single row that returns data from all three tables, and three rows that retur...
snowflake_docs/regr_valy_5_0.txt
Examples ¶ Basic example: > > SELECT REGR_VALY(NULL, 10), REGR_VALY(1, NULL), REGR_VALY(1, 10); > +---------------------+--------------------+------------------+ > | REGR_VALY(NULL, 10) | REGR_VALY(1, NULL) | REGR_VALY(1, 10) | > |---------------------+--------------------+------------------| > |...
snowflake_docs/database_replication_usage_history_1_0.txt
DATABASE_REPLICATION_USAGE_HISTORY View ¶ This Account Usage view can be used to query the database replication history. The returned results include the database name, credits consumed, and bytes transferred for replication. Usage data is retained for 365 days (1 year).
snowflake_docs/try_to_binary_5_0.txt
Usage Notes ¶ * Only works for string expressions. * If ` _ format _ ` is specified but is not HEX, BASE64, or UTF-8, the result will be a NULL value.
snowflake_docs/system_clustering_information_3_0.txt
Arguments ¶ ` _ table_name _ ` Table for which you want to return clustering information. ` ( _ expr1 _ [ , _ expr2 _ ... ]) ` Column names or expressions for which clustering information is returned: * For a table with no clustering key, this argument is required. If this argument is omitted, an error is ...
snowflake_docs/search_optimization_history_1_0.txt
SEARCH_OPTIMIZATION_HISTORY View ¶ This feature requires Enterprise Edition (or higher). To inquire about upgrading, please contact [ Snowflake Support Snowflake-Lodge) . guide/search-optimization-service) history. The information returned by the view includes the search optimization service name and credits consume...
snowflake_docs/account-usage_16_0.txt
Selecting Columns ¶ The Snowflake-specific views are subject to change. Avoid selecting all columns from these views. Instead, select the columns that you want. For example, if you want the ` name ` column, use ` SELECT name ` , rather than ` SELECT * ` .
snowflake_docs/warehouse_load_history_3_0.txt
Usage Notes ¶ * Latency for the view may be up to 180 minutes (3 hours). * Load history is shown in 5-minute intervals. Was this page helpful? Yes No Inc. All Rights Reserved . On this page 1. Columns 2. Usage Notes Language : **English**
snowflake_docs/alter-notification-integration_0_0.txt
/ 1. General 7. API 10. Catalog 15. External access 18. Notification 21. Security 25. Storage NOTIFICATION INTEGRATION
snowflake_docs/data-types-logical_3_0.txt
BOOLEAN ¶ BOOLEAN can have TRUE or FALSE values. BOOLEAN can also have an “unknown” value, which is represented by NULL. Boolean columns can be used in
snowflake_docs/desc-alert_2_0.txt
Syntax ¶ DESC[RIBE] ALERT <name> Copy
snowflake_docs/uniform_3_0.txt
Arguments ¶ ` _ min _ ` A constant specifying the minimum value (inclusive) of the generated number. ` _ max _ ` A constant specifying the maximum value (inclusive) of the generated number. ` _ gen _ ` An expression that serves as a raw source of uniform random numbers, typically the ` RANDOM ` function. For mor...
snowflake_docs/tag_references_with_lineage_2_0.txt
Syntax ¶ TAG_REFERENCES_WITH_LINEAGE( '<name>' ) Copy
snowflake_docs/st_transform_5_0.txt
Returns ¶ types-geometry) object that uses the SRS identified by ` _ to_srid _ ` .
snowflake_docs/st_makepoint_1_0.txt
ST_MAKEPOINT , ST_POINT ¶ geography) object that represents a point with the specified longitude and latitude. See also:
snowflake_docs/data-types-semistructured_8_0.txt
OBJECT ¶ other programming languages, the corresponding data type is often called a “dictionary”, “hash”, or “map”. An OBJECT contains key-value pairs.
snowflake_docs/listing-telemetry-daily_1_0.txt
LISTING_TELEMETRY_DAILY View ¶ The LISTING_TELEMETRY_DAILY view in the DATA_SHARING_USAGE schema displays daily telemetry data by data exchange and region. The view returns a row for each data exchange in your organization and each region where that data exchange is available.
snowflake_docs/system_registry_list_images_5_0.txt
Usage notes ¶ * You need the read permission on the repository to get a list of images.
snowflake_docs/budget_3_0.txt
Budget Functions ¶
snowflake_docs/st_y_7_0.txt
GEOGRAPHY Examples ¶ This shows a simple use of the ST_X and ST_Y functions with VARCHAR data: > > SELECT ST_X(ST_MAKEPOINT(37.5, 45.5)), ST_Y(ST_MAKEPOINT(37.5, 45.5)); > +--------------------------------+--------------------------------+ > | ST_X(ST_MAKEPOINT(37.5, 45.5)) | ST_Y(ST_MAKEPOINT(37.5, 45.5...
snowflake_docs/create-account_5_0.txt
label-region-groups) . Default: Current region group. ` REGION = _ snowflake_region_id _ ` snowflake-region-ids) of the region where the account is created. If no value is provided, Snowflake creates the account in the same Snowflake Region as the current account (i.e. the account in which the CREATE ACCOUNT stateme...
snowflake_docs/show-columns_6_1.txt
| | TEST1 | | | DT_TEST | PUBLIC | B1 | {"type":"BINARY","length":8388608,"byteLength":8388608,"nullable":true,"fixed":true} | true | | COLUMN | | | TEST1 | | | DT_TEST | ...
snowflake_docs/show-secrets_5_0.txt
label-access-control-overview-privileges) at a minimum: Privilege | Object | Notes ---|---|--- USAGE | Secret | Note that operating on any object in a schema also requires the USAGE privilege on the parent database and schema. For instructions on creating a custom role with a specified set of privileges, configur...
snowflake_docs/create-table-constraint_5_0.txt
Constraint Properties ¶ For compatibility with other databases, Snowflake provides constraint properties. The properties that can be specified for a constraint depend on the type: * Some properties apply to all keys (unique, primary, and foreign). * Other properties apply only to foreign keys. Important These ...
snowflake_docs/listagg_3_0.txt
Arguments ¶ **Required:** ` _ expr1 _ ` An expression (typically a column name) that determines the values to be put into the list. The expression should evaluate to a string, or to a data type that can be cast to string. ` OVER() ` The OVER clause specifies that the function is being used as a window **Optional:*...
snowflake_docs/system_cancel_job_0_0.txt
/ 1. Control 29. Information 90. Query Information SYSTEM$CANCEL_JOB Categories:
snowflake_docs/replication_usage_history_0_0.txt
/ 1. Data Loading 4. Data Generation 6. Data Conversion 9. ML-Powered Analysis 11. Object Modeling 13. Semi-Structured Queries 15. Query Results 17. Query Profile 19. User Login 22. Queries 26. Wareho...
snowflake_docs/system_verify_ext_oauth_token_3_0.txt
Arguments ¶ ` _ access_token _ ` The External OAuth access token generated by your OAuth 2.0 server.
snowflake_docs/data-types-structured_22_0.txt
Using ARRAY and OBJECT Constants to Construct Structured ARRAYs and OBJECTs ¶ semistructured.html
snowflake_docs/alter-procedure_0_0.txt
/ 1. User Defined Function 7. External Function 13. Stored Procedure 21. Snowflake Scripting function) ALTER PROCEDURE
snowflake_docs/undrop-tag_2_0.txt
Syntax ¶ UNDROP TAG <name> Copy
snowflake_docs/create-masking-policy_1_0.txt
CREATE MASKING POLICY ¶ This feature requires Enterprise Edition (or higher). To inquire about upgrading, please contact [ Snowflake Support Snowflake-Lodge) . Creates a new masking policy in the current/specified schema or replaces an existing masking policy. After creating a masking policy, apply the masking polic...
snowflake_docs/array_max_4_0.txt
Returns ¶ data-type-variant) that contains the element with the highest value that is not a SQL NULL. The function returns NULL if ` _ array _ ` is NULL, empty, or contains only SQL NULL elements.
snowflake_docs/drop-authentication-policy_5_0.txt
label-access-control-overview-privileges) at a minimum: Privilege | Object | Notes ---|---|--- OWNERSHIP | Authentication policy | OWNERSHIP is a special privilege on an object that is automatically granted to the role that created the object, but can also be transferred using the [ role (or any role with the MANAG...
snowflake_docs/collation_24_0.txt
Differences in Handling Ignorable Code Points ¶ The Unicode Collation Algorithm specifies that collation elements (code points) can be [ ignorable means that a code point is not considered during string comparison and sorting. * With the ` ci ` collation specification, these code points are ignored. This can make...
snowflake_docs/copy_history_6_0.txt
Examples ¶ Retrieve details about all loading activity in the last hour: > > select * > from table(information_schema.copy_history(TABLE_NAME=>'MYTABLE', > START_TIME=> DATEADD(hours, -1, CURRENT_TIMESTAMP()))); > > > Copy Was this page helpful? Yes No Inc. All Rights Reserved . On this page 1. Syntax...
snowflake_docs/drop-application_0_0.txt
/ 1. APPLICATION 7. APPLICATION PACKAGE 12. APPLICATION ROLE 19. Additional Commands DROP APPLICATION
snowflake_docs/desc-network-rule_2_0.txt
Syntax ¶ DESC[RIBE] NETWORK RULE <name> Copy
snowflake_docs/array_insert_1_0.txt
ARRAY_INSERT ¶ Returns an array containing all elements from the source array as well as the new element.
snowflake_docs/desc-table_1_0.txt
DESCRIBE TABLE ¶ Describes either the columns in a table or the current values, as well as the default values, for the stage properties for a table. DESCRIBE can be abbreviated to DESC. See also:
snowflake_docs/hex_decode_binary_1_0.txt
HEX_DECODE_BINARY ¶ Decodes a hex-encoded string to a binary. See also:
snowflake_docs/associate_semantic_category_tags_0_0.txt
/ 1. Alerts 3. Data Classification procedures) ASSOCIATE_SEMANTIC_CATEGORY_TAGS
snowflake_docs/alter-sequence_1_0.txt
ALTER SEQUENCE ¶ Modifies the properties for an existing sequence. See also:
snowflake_docs/as_1_0.txt
AS_ _ <object_type> _ ¶ This family of functions can be used to perform strict casting of VARIANT values to other data types: > > > > > > > > > > > See also:
snowflake_docs/order-by_4_0.txt
Examples ¶ Sort order example for strings: > > SELECT column1 > FROM VALUES ('a'), ('1'), ('B'), (null), ('2'), ('01'), ('05'), (' > this'), ('this'), ('this and that'), ('&'), ('%') > ORDER BY column1; > > +---------------+ > | COLUMN1 | > |---------------| > | this | > ...
snowflake_docs/strtok_to_array_5_0.txt
Examples ¶ Here is a simple example of using ` STRTOK_TO_ARRAY ` to split a string into an array: > > SELECT STRTOK_TO_ARRAY('a.b.c', '.'); > +-------------------------------+ > | STRTOK_TO_ARRAY('A.B.C', '.') | > |-------------------------------| > | [ | > | "a...
snowflake_docs/months_between_2_0.txt
Syntax ¶ MONTHS_BETWEEN( <date_expr1> , <date_expr2> ) Copy
snowflake_docs/create-view_13_0.txt
Examples ¶ Create a view in the current schema, with a comment, that selects all the rows from a table: > > CREATE VIEW myview COMMENT='Test view' AS SELECT col1, col2 FROM > mytable; > > SHOW VIEWS; > > > +---------------------------------+-------------------+----------+---------------+-------------+---...
snowflake_docs/asof-join_3_0.txt
Usage Notes ¶ * If no match is found in the right table for a given row, the result is null-padded for the selected columns from the right table. (ASOF joins are similar to left outer joins in this respect.) * More than one ASOF join can be used in the same query as long as all of the syntax rules are followed ...
snowflake_docs/year_2_0.txt
Syntax ¶ YEAR( <date_or_timestamp_expr> ) YEAROFWEEK( <date_or_timestamp_expr> ) YEAROFWEEKISO( <date_or_timestamp_expr> ) DAY( <date_or_timestamp_expr> ) DAYOFMONTH( <date_or_timestamp_expr> ) DAYOFWEEK( <date_or_timestamp_expr> ) DAYOFWEEKISO( <date_or_timestamp_expr> ) DAYOFYEAR( <...
snowflake_docs/create-account_8_0.txt
Examples ¶ Create a new account in the ` aws_us_west_2 ` Snowflake Region on Amazon Web Services (AWS). The user who executes the CREATE ACCOUNT statement can be logged into an account in the same or a different Snowflake Region: > > create account myaccount1 > admin_name = admin > admin_password = ...
snowflake_docs/desc-share_2_0.txt
Syntax ¶ **Providers (outbound share)** DESC[RIBE] SHARE <name> Copy **Consumers (inbound share)** DESC[RIBE] SHARE <provider_account>.<share_name> Copy
snowflake_docs/drop-task_2_0.txt
Syntax ¶ DROP TASK [ IF EXISTS ] <name> Copy
snowflake_docs/in_0_0.txt
/ reference/expressions-conditional) [NOT] IN Categories:
snowflake_docs/is_database_role_in_session_4_1.txt
prise Edition or higher. Snowflake recommends using this function when the policy conditions need to evaluate role hierarchy and inherited privileges. * Result cache: If you use this function in a masking policy or row access policy and neither the policy nor the table or column protected by the policy change from a...
snowflake_docs/use-role_4_0.txt
Usage notes ¶ * To use a role, the role must have been granted to the user. * Only a single primary role can be active at a time in a user session. overview.html
snowflake_docs/alter-api-integration_4_0.txt
Usage Notes ¶ * The API_PROVIDER cannot be changed. * Regarding metadata: Attention Customers should ensure that no personal data (other than for a User object), sensitive data, export-controlled data, or other regulated data is entered as metadata when using the Snowflake service. For more information, see [
snowflake_docs/create-sequence_11_0.txt
Examples ¶ Here is a simple example of using sequences: > > >> CREATE OR REPLACE SEQUENCE seq_01 START = 1 INCREMENT = 1; >> CREATE OR REPLACE TABLE sequence_test_table (i INTEGER); >> >> >> Copy >> >> >> SELECT seq_01.nextval; >> +---------+ >> | NEXTVAL | >> |---------| >> | ...
snowflake_docs/st_contains_4_0.txt
Returns ¶ BOOLEAN.
snowflake_docs/system_whitelist_4_0.txt
Returns ¶ The data type of the returned value is VARIANT. The value is an array of JSON structures. Each JSON structure contains three key/value pairs: ` type ` Snowflake supports the following types: ` SNOWFLAKE_DEPLOYMENT ` Hostname and port number information for your Snowflake account. ` SNOWFLAKE_DEPLOYMENT_R...
snowflake_docs/desc-transaction_4_0.txt
Usage Notes ¶
snowflake_docs/h3_coverage_2_0.txt
label-data-types-geography) object). See also:
snowflake_docs/external_tables_0_0.txt
/
snowflake_docs/revoke-privilege-share_5_0.txt
Examples ¶ > > REVOKE SELECT ON VIEW mydb.shared_schema.view1 FROM SHARE share1; > > REVOKE SELECT ON VIEW mydb.shared_schema.view3 FROM SHARE share1; > > REVOKE USAGE ON SCHEMA mydb.shared_schema FROM SHARE share1; > > REVOKE SELECT ON ALL TABLES IN SCHEMA mydb.public FROM SHARE share1; > > ...
snowflake_docs/tags_3_0.txt
label-object-tagging-specify-tag-values) . OWNER_ROLE_TYPE | TEXT | The type of role that owns the object, either ` ROLE ` or ` DATABASE_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 does not have ...