SYSTEM$ENCODE_CKE_PRIMARY_KEY

functionsupportedIntegrations, network & secrets

docs.snowflake.com ↗

System functions

Takes one or more primary key columns from a Cortex Knowledge Extensions (CKE) document and converts them into an encoded representation. The encoded primary key is used as an input for further hashing, which anonymizes document identifiers in access history tables. This process helps protect customer data by ensuring that Snowflake stores hashed values derived from the encoded primary key instead of plain-text document IDs.

Syntax

supportedpartialnot supportednot scored

SYSTEM$ENCODE_CKE_PRIMARY_KEY(
  '<pk_column_name>'
  [ , '<additional_pk_column_name>' ]
  [ , '<additional_pk_column_name>' ]
  [ , '<additional_pk_column_name>' ]
  [ , '<additional_pk_column_name>' ]
)

Parameters

NameRequiredDescription
pk_column_namerequiredThe primary key column name.
additional_pk_column_nameoptionalAdditional primary key column names. You can specify up to four additional primary key column names as separate arguments.

Returns

Returns a length-encoded string from the combined primary keys. This serves as the unique document ID.

See also

Referenced by