Creating and Replacing Authorization | Examples | Teradata Connector | QueryGrid - Examples of Creating and Replacing the Authorization - Teradata QueryGrid

QueryGridâ„¢ Installation and User Guide - 3.06

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
Lake
VMware
Product
Teradata QueryGrid
Release Number
3.06
Published
December 2024
ft:locale
en-US
ft:lastEdition
2024-12-07
dita:mapPath
ndp1726122159943.ditamap
dita:ditavalPath
ft:empty
dita:id
lxg1591800469257
Product Category
Analytical Ecosystem

If you plan to use the authorization to authenticate to Kerberos on a foreign server then you must use either INVOKER TRUSTED or DEFINER TRUSTED.

The following two examples establish authorization for the user who invokes the object. The credentials are encrypted and stored as a database object in the user database.

CREATE AUTHORIZATION sales AS INVOKER TRUSTED
  USER 'johnson'
  PASSWORD 'Secret' ;
REPLACE AUTHORIZATION sales AS TRUSTED
  USER 'williams'
  PASSWORD 'topsecret' ;

If you want to make the authorization available globally, create the authorization on TD_SERVER_DB using the DEFINER TRUSTED type. If you use DEFINER TRUSTED, as in this example, then the credentials for proxy_1 are stored in the remote_system1 authorization that is created in the TD_SERVER_DB database.

CREATE AUTHORIZATION TD_SERVER_DB.remote_system1 
AS DEFINER TRUSTED USER 'proxy_1'
  PASSWORD 'Global' ;