Attribute

ServiceAccountKeyContent (SAKC)

Purpose

Specifies the private key required to authenticate to a Google BigQuery instance when service account authentication is enabled (AuthenticationMethod=serviceaccount). The private key is obtained from the private key file. The private key file can be downloaded from Google Cloud Platform (GCP) Console.

To learn more about service accounts and service account private keys, refer to Google documentation.

Valid Values

string

where:

string
is the value of the private_key property in the private key file downloaded from the Google Cloud Platform (GCP) Console. Surrounding quotation marks should be omitted when specifying the value.

Notes

  • The value of the Service Account Key Content option should be protected for security reasons. The option has been intentionally excluded from the Windows Setup dialog. In addition, the value should not be hardcoded in an ODBC data source. Rather, it may be specified in the application with the SQLConnect ODBC API, in a connection string as with SQLDriverConnect and SQLBrowseConnect, or through the Logon dialog prompt. (If your operating system supports the Logon dialog, the prompt appears when the value has not been otherwise specified.)

  • Either Service Account Key Content or Service Account Private Key may be used to configure service account authentication. Service Account Key Content specifies the private key itself, whereas Service Account Private Key specifies the full path to the .json or .p12 file that contains the private key. When Service Account Key Content is used, the specified private key is used to authenticate the user with the database. When Service Account Private Key is used, the driver extracts the private key value from the specified file and uses it to authenticate the user to the database. If you do not want to persist the private key file in your environment, you should use the Service Account Key Content option. If Service Account Key Content and Service Account Private Key are both specified, the Service Account Key Content option will be used to connect to Google BigQuery.

Example

When specifying the value of Service Account Key Content as with this connection string example, surrounding quotation marks should be omitted.

ServiceAccountKeyContent=NJJXZexIHJFGYBgkqhkiG9w0BAQnWRwiHANpf3MC1pVRqhtTE5tSpxZeQnICG
4zp087Eidn4qc66udg8KAHknyqFdj7b\n+MgxMFPAvJ59cylHFaHA4pGmeGfVqzYub6LEs9aN/751jmZqcuAYp
5nXRF1EvJPN\nsDuJGLvuuDBZW0iux0liEHmcQVBBKwIx8t+EQxePGTiLsBoCdzOUsi4UWWv\nASqfdP/kSX+N

Default

None

GUI Tab

None

See also

Configuring service account authentication

Service Account Email

Service Account Private Key