Adapter Online Help > TDV Snowflake Adapter > Data Model > Stored Procedures
 
Stored Procedures
Stored procedures are available to complement the data available from the Data Model. It may be necessary to update data available from a view using a stored procedure because the data does not provide for direct, table-like, two-way updates. In these situations, the retrieval of the data is done using the appropriate view or table, while the update is done by calling a stored procedure. Stored procedures take a list of parameters and return back a dataset that contains the collection of tuples that constitute the response.
Snowflake Adapter Stored Procedures
Name
Description
If using a Windows application, set Authmode to App. If using a Web app, set Authmode to Web and specify the Verifier obtained by GetOAuthAuthorizationUrl.
Gets the authorization URL that must be opened separately by the user to grant access to your application. Only needed when developing Web apps.
Gets Browser-based SSO authorization URL. Access the URL returned in the output in a Web browser. This requests the access token that can be used as part of the connection string to Snowflake.
Refreshes the OAuth access token used for authentication with Snowflake.
GetOAuthAccessToken
If using a Windows application, set Authmode to App. If using a Web app, set Authmode to Web and specify the Verifier obtained by GetOAuthAuthorizationUrl.
Input
Name
Type
Required
Description
AuthMode
String
False
The type of authentication mode to use. The allowed values are APP, WEB.
CallbackUrl
String
False
The page to return the user after authorization is complete.
Verifier
String
False
The verifier code returned by Snowflake after permissions have been granted for the app to connect. WEB Authmode only.
PKCEVerifier
String
False
The PKCEVerifier returned by GetOAuthAuthorizationURL.
Prompt
String
False
Defaults to 'select_account' which prompts the user to select account while authenticating. Set to 'None', for no prompt, 'login' to force user to enter their credentials or 'consent' to trigger the OAuth consent dialog after the user signs in, asking the user to grant permissions to the app.
 
Result Set Columns
 
Name
Type
Description
OAuthRefreshToken
String
A token that may be used to obtain a new access token.
OAuthAccessToken
String
The OAuth access token.
ExpiresIn
String
The remaining lifetime on the access token. A -1 denotes that it will not expire.
GetOAuthAuthorizationUrl
Name
Type
Description
OAuthRefreshToken
String
A token that may be used to obtain a new access token.
OAuthAccessToken
String
The OAuth access token.
ExpiresIn
String
The remaining lifetime on the access token. A -1 denotes that it will not expire.
Gets the authorization URL that must be opened separately by the user to grant access to your application. Only needed when developing Web apps.
Input
 
Name
Type
Required
Description
CallbackUrl
String
False
The page to return the user after authorization is complete.
Scope
String
False
The scope of access to Snowflake. The scope parameters in the initial authorization request optionally limit the operations and role permitted by the access token, the default scope was refresh_token.
State
String
False
Any value that you wish to be sent with the callback.
Prompt
String
False
Defaults to 'select_account' which prompts the user to select account while authenticating. Set to 'None', for no prompt, 'login' to force user to enter their credentials or 'consent' to trigger the OAuth consent dialog after the user signs in, asking the user to grant permissions to the app.
Result Set Columns
Name
Type
Description
Url
String
The authorization url.
PKCEVerifier
String
A random value used as input for GetOAuthAccessToken in the PKCE flow.
GetSSOAuthorizationURL
Gets Browser-based SSO authorization URL. Access the URL returned in the output in a Web browser. This requests the access token that can be used as part of the connection string to Snowflake.
Input
Name
Type
Required
Description
Port
String
False
The listening port of the callback url.
The default value is 80.
 
Result Set Columns
Name
Type
Description
ProofKey
String
 
SSOURL
String
 
TokenURL
String
 
 
RefreshOAuthAccessToken
Refreshes the OAuth access token used for authentication with Snowflake.
Input
Name
Type
Required
Description
OAuthRefreshToken
String
True
Set this to the token value that expired.
Result Set Columns
Name
Type
Description
OAuthAccessToken
String
The authentication token returned from AzureDataCatalog. This can be used in subsequent calls to other operations for this particular service.
OAuthRefreshToken
String
This is the same as the access token.
ExpiresIn
String
The remaining lifetime on the access token.