CData Cloud offers access to Azure Synapse across several standard services and protocols, in a cloud-hosted solution. Any application that can connect to a MySQL or SQL Server database can connect to Azure Synapse through CData Cloud.
CData Cloud allows you to standardize and configure connections to Azure Synapse as though it were any other OData endpoint, or standard SQL Server/MySQL database.
This page provides a guide to Establishing a Connection to Azure Synapse in CData Cloud, as well as information on the available resources, and a reference to the available connection properties.
Establishing a Connection shows how to authenticate to Azure Synapse and configure any necessary connection properties to create a database in CData Cloud
Accessing data from Azure Synapse through the available standard services and CData Cloud administration is documented in further details in the CData Cloud Documentation.
Connect to Azure Synapse by selecting the corresponding icon in the Database tab. Required properties are listed under Settings. The Advanced tab lists connection properties that are not typically required.
In addition to providing authentication (see below), set the following properties to connect to a Azure Synapse database:
Connect to Azure Synapse using the following properties:
Azure Service Principal is role-based application-based authentication. This means that authentication is done per application, rather than per user. All tasks taken on by the application are executed without a default user context, but based on the assigned roles. The application access to the resources is controlled through the assigned roles' permissions.
For information about how to set up Azure Service Principal authentication, see Creating a Custom OAuth Application.
If you are running Azure Synapse on an Azure VM and want to leverage MSI to connect, set AuthScheme to AzureMSI.
When your VM has multiple user-assigned managed identities, you must also specify OAuthClientId.
Azure Service Principal is role-based application-based authentication. This means that authentication is done per application, rather than per user. All tasks taken by the app are done without a default user context, but based on the assigned roles. The application access to the resources is controlled through the assigned roles' permissions.
To use Azure Service Principal authentication, you must:
Do the following:
All permissions related to the client OAuth flow require admin consent. This means you cannot use the application embedded with the CData Cloud in the client OAuth flow. You must create your own OAuth application to use client credentials. See Creating a Custom OAuth Application for more information.
In your App Registration in portal.azure.com, navigate to API Permissions and select the Microsoft Graph permissions. There are two distinct sets of permissions: Delegated permissions and Application permissions. The permissions used during client credential authentication are under "Application Permissions".
Select the permissions you require for your integration. After you do this, set the following connection properties:
Authentication with client credentials takes place automatically like any other connection, except there is no window opened prompting the user. Because there is no user context, there is no need for a browser popup. Connections will take place and be handled internally.
By default, the Cloud attempts to negotiate SSL/TLS by checking the server's certificate against the system's trusted certificate store.
To specify another certificate, see the SSLServerCert property for the available formats to do so.
The Azure Synapse Cloud also supports setting client certificates. Set the following to connect using a client certificate.
Set the following properties:
Stored procedures are function-like interfaces that extend the functionality of the Cloud beyond simple SELECT/INSERT/UPDATE/DELETE operations with Azure Synapse.
Stored procedures accept a list of parameters, perform their intended function, and then return any relevant response data from Azure Synapse, along with an indication of whether the procedure succeeded or failed.
Name | Description |
The connection string properties are the various options that can be used to establish a connection. This section provides a complete list of the options you can configure in the connection string for this provider. Click the links for further details.
For more information on establishing a connection, see Establishing a Connection.
Property | Description |
AuthScheme | The scheme used for authentication. Accepted entries are Password, AzureAD, AzureServicePrincipal, AzureServicePrincipalCert, AzureMSI, AzurePassword. |
Server | The name of the server running Synapse. |
User | The Azure Synapse user account used to authenticate. |
Password | The password used to authenticate the user. |
Port | The port of the Synapse. |
Database | The name of the Synapse database. |
Encrypt | This field sets whether SSL is enabled. |
Property | Description |
BatchMode | The Batch Mode of Azure Synapse bulkInsert. |
StorageAccountLocation | The Storage Account Location for staging your data. |
AzureSASToken | The string value of the Azure Blob shared access signature. |
Property | Description |
AzureTenant | The Microsoft Online tenant being used to access data. If not specified, your default tenant is used. |
AzureEnvironment | The Azure Environment to use when establishing a connection. |
Property | Description |
OAuthClientId | The client Id assigned when you register your application with an OAuth authorization server. |
OAuthClientSecret | The client secret assigned when you register your application with an OAuth authorization server. |
OAuthGrantType | The grant type for the OAuth flow. |
Property | Description |
OAuthJWTCert | The JWT Certificate store. |
OAuthJWTCertType | The type of key store containing the JWT Certificate. |
OAuthJWTCertPassword | The password for the OAuth JWT certificate. |
OAuthJWTCertSubject | The subject of the OAuth JWT certificate. |
Property | Description |
SSLServerCert | The certificate to be accepted from the server when connecting using TLS/SSL. |
Property | Description |
Verbosity | The verbosity level that determines the amount of detail included in the log file. |
Property | Description |
BrowsableSchemas | This property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC. |
Property | Description |
CustomizeDateFormat | Configure the Date format. |
ApplicationIntent | Expresses the client application's request to be directed either to a read-write or read-only version of an availability group database. |
EnableTransaction | Determines whether transactions are enabled. |
MaxRows | Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses. |
Timeout | The value in seconds until the timeout error is thrown, canceling the operation. |
This section provides a complete list of the Authentication properties you can configure in the connection string for this provider.
Property | Description |
AuthScheme | The scheme used for authentication. Accepted entries are Password, AzureAD, AzureServicePrincipal, AzureServicePrincipalCert, AzureMSI, AzurePassword. |
Server | The name of the server running Synapse. |
User | The Azure Synapse user account used to authenticate. |
Password | The password used to authenticate the user. |
Port | The port of the Synapse. |
Database | The name of the Synapse database. |
Encrypt | This field sets whether SSL is enabled. |
The scheme used for authentication. Accepted entries are Password, AzureAD, AzureServicePrincipal, AzureServicePrincipalCert, AzureMSI, AzurePassword.
string
"Password"
Together with Password and User, this field is used to authenticate against the server. Password is the default option. Use the following options to select your authentication scheme:
The name of the server running Synapse.
string
""
Set this property to the name or network address of the Synapse instance.
The Azure Synapse user account used to authenticate.
string
""
Together with Password, this field is used to authenticate against the Azure Synapse server.
The password used to authenticate the user.
string
""
The User and Password are together used to authenticate with the server.
The name of the Synapse database.
string
""
The name of the Synapse database running on the specified Server.
This field sets whether SSL is enabled.
bool
true
This field sets whether the Cloud will attempt to negotiate TLS/SSL connections to the server. By default, the Cloud checks the server's certificate against the system's trusted certificate store. To specify another certificate, set SSLServerCert.
This section provides a complete list of the Bulk properties you can configure in the connection string for this provider.
Property | Description |
BatchMode | The Batch Mode of Azure Synapse bulkInsert. |
StorageAccountLocation | The Storage Account Location for staging your data. |
AzureSASToken | The string value of the Azure Blob shared access signature. |
The Batch Mode of Azure Synapse bulkInsert.
string
"COPY"
COPY utilizes an external storage account to load data into and then copy into your Azure Synapse table. You will also need to set the StorageAccountLocation and the AzureSASToken, which only supports INSERT statement. BCP transfers data to Azure Synapse directly with BulkLoadBCP protocol through the TCP communication between client and server, which only supports INSERT statements. STANDARD uses standard INSERT, UPDATE and DELETE statements for batch operations.
The Storage Account Location for staging your data.
string
""
Specify the file location in AzureBlob(only for COPY mode).
"myaccount" here is your Azure Blob account name, "myblobcontainer" is the Blob container you want to use. For example: https://myaccount.blob.core.windows.net/myblobcontainer/...
The string value of the Azure Blob shared access signature.
string
""
The string value of the Azure Blob shared access signature.
You can go to "Shared access signature" in "Settings" section for your Azure Blob container through Azure Portal, then click "Generate SAS token and URL" and copy the value from "Blob SAS token" textbox. Please be cautionus to select the proper permission (Create, Write, Delete) in "Permissions" dropdown list and validity of Start and Expiry time before you generate SAS token.
This section provides a complete list of the Azure Authentication properties you can configure in the connection string for this provider.
Property | Description |
AzureTenant | The Microsoft Online tenant being used to access data. If not specified, your default tenant is used. |
AzureEnvironment | The Azure Environment to use when establishing a connection. |
The Microsoft Online tenant being used to access data. If not specified, your default tenant is used.
string
""
The Microsoft Online tenant being used to access data. For instance, contoso.onmicrosoft.com. Alternatively, specify the tenant Id. This value is the directory Id in the Azure Portal > Azure Active Directory > Properties.
Typically it is not necessary to specify the Tenant. This can be automatically determined by Microsoft when using the OAuthGrantType set to CODE (default). However, it may fail in the case that the user belongs to multiple tenants. For instance, if an Admin of domain A invites a user of domain B to be a guest user. The user will now belong to both tenants. It is a good practice to specify the Tenant, although in general things should normally work without having to specify it.
The AzureTenant is required when setting OAuthGrantType to CLIENT. When using client credentials, there is no user context. The credentials are taken from the context of the app itself. While Microsoft still allows client credentials to be obtained without specifying which Tenant, it has a much lower probability of picking the specific tenant you want to work with. For this reason, we require AzureTenant to be explicitly stated for all client credentials connections to ensure you get credentials that are applicable for the domain you intend to connect to.
The Azure Environment to use when establishing a connection.
string
"GLOBAL"
In most cases, leaving the environment set to global will work. However, if your Azure Account has been added to a different environment, the AzureEnvironment may be used to specify which environment. The available values are GLOBAL, CHINA, USGOVT, USGOVTDOD.
This section provides a complete list of the OAuth properties you can configure in the connection string for this provider.
Property | Description |
OAuthClientId | The client Id assigned when you register your application with an OAuth authorization server. |
OAuthClientSecret | The client secret assigned when you register your application with an OAuth authorization server. |
OAuthGrantType | The grant type for the OAuth flow. |
The client Id assigned when you register your application with an OAuth authorization server.
string
""
As part of registering an OAuth application, you will receive the OAuthClientId value, sometimes also called a consumer key, and a client secret, the OAuthClientSecret.
The client secret assigned when you register your application with an OAuth authorization server.
string
""
As part of registering an OAuth application, you will receive the OAuthClientId, also called a consumer key. You will also receive a client secret, also called a consumer secret. Set the client secret in the OAuthClientSecret property.
The grant type for the OAuth flow.
string
"CODE"
The following options are available: CODE,CLIENT,PASSWORD
This section provides a complete list of the JWT OAuth properties you can configure in the connection string for this provider.
Property | Description |
OAuthJWTCert | The JWT Certificate store. |
OAuthJWTCertType | The type of key store containing the JWT Certificate. |
OAuthJWTCertPassword | The password for the OAuth JWT certificate. |
OAuthJWTCertSubject | The subject of the OAuth JWT certificate. |
The JWT Certificate store.
string
""
The name of the certificate store for the client certificate.
The OAuthJWTCertType field specifies the type of the certificate store specified by OAuthJWTCert. If the store is password protected, specify the password in OAuthJWTCertPassword.
OAuthJWTCert is used in conjunction with the OAuthJWTCertSubject field in order to specify client certificates. If OAuthJWTCert has a value, and OAuthJWTCertSubject is set, a search for a certificate is initiated. Please refer to the OAuthJWTCertSubject field for details.
Designations of certificate stores are platform-dependent.
The following are designations of the most common User and Machine certificate stores in Windows:
MY | A certificate store holding personal certificates with their associated private keys. |
CA | Certifying authority certificates. |
ROOT | Root certificates. |
SPC | Software publisher certificates. |
In Java, the certificate store normally is a file containing certificates and optional private keys.
When the certificate store type is PFXFile, this property must be set to the name of the file. When the type is PFXBlob, the property must be set to the binary contents of a PFX file (i.e. PKCS12 certificate store).
The type of key store containing the JWT Certificate.
string
"PEMKEY_BLOB"
This property can take one of the following values:
USER | For Windows, this specifies that the certificate store is a certificate store owned by the current user. Note: This store type is not available in Java. |
MACHINE | For Windows, this specifies that the certificate store is a machine store. Note: this store type is not available in Java. |
PFXFILE | The certificate store is the name of a PFX (PKCS12) file containing certificates. |
PFXBLOB | The certificate store is a string (base-64-encoded) representing a certificate store in PFX (PKCS12) format. |
JKSFILE | The certificate store is the name of a Java key store (JKS) file containing certificates. Note: this store type is only available in Java. |
JKSBLOB | The certificate store is a string (base-64-encoded) representing a certificate store in Java key store (JKS) format. Note: this store type is only available in Java. |
PEMKEY_FILE | The certificate store is the name of a PEM-encoded file that contains a private key and an optional certificate. |
PEMKEY_BLOB | The certificate store is a string (base64-encoded) that contains a private key and an optional certificate. |
PUBLIC_KEY_FILE | The certificate store is the name of a file that contains a PEM- or DER-encoded public key certificate. |
PUBLIC_KEY_BLOB | The certificate store is a string (base-64-encoded) that contains a PEM- or DER-encoded public key certificate. |
SSHPUBLIC_KEY_FILE | The certificate store is the name of a file that contains an SSH-style public key. |
SSHPUBLIC_KEY_BLOB | The certificate store is a string (base-64-encoded) that contains an SSH-style public key. |
P7BFILE | The certificate store is the name of a PKCS7 file containing certificates. |
PPKFILE | The certificate store is the name of a file that contains a PPK (PuTTY Private Key). |
XMLFILE | The certificate store is the name of a file that contains a certificate in XML format. |
XMLBLOB | The certificate store is a string that contains a certificate in XML format. |
The password for the OAuth JWT certificate.
string
""
If the certificate store is of a type that requires a password, this property is used to specify that password in order to open the certificate store.
The subject of the OAuth JWT certificate.
string
"*"
When loading a certificate the subject is used to locate the certificate in the store.
If an exact match is not found, the store is searched for subjects containing the value of the property.
If a match is still not found, the property is set to an empty string, and no certificate is selected.
The special value "*" picks the first certificate in the certificate store.
The certificate subject is a comma separated list of distinguished name fields and values. For instance "CN=www.server.com, OU=test, C=US, [email protected]". Common fields and their meanings are displayed below.
Field | Meaning |
CN | Common Name. This is commonly a host name like www.server.com. |
O | Organization |
OU | Organizational Unit |
L | Locality |
S | State |
C | Country |
E | Email Address |
If a field value contains a comma it must be quoted.
This section provides a complete list of the SSL properties you can configure in the connection string for this provider.
Property | Description |
SSLServerCert | The certificate to be accepted from the server when connecting using TLS/SSL. |
The certificate to be accepted from the server when connecting using TLS/SSL.
string
""
If using a TLS/SSL connection, this property can be used to specify the TLS/SSL certificate to be accepted from the server. Any other certificate that is not trusted by the machine is rejected.
This property can take the following forms:
Description | Example |
A full PEM Certificate (example shortened for brevity) | -----BEGIN CERTIFICATE----- MIIChTCCAe4CAQAwDQYJKoZIhv......Qw== -----END CERTIFICATE----- |
A path to a local file containing the certificate | C:\cert.cer |
The public key (example shortened for brevity) | -----BEGIN RSA PUBLIC KEY----- MIGfMA0GCSq......AQAB -----END RSA PUBLIC KEY----- |
The MD5 Thumbprint (hex values can also be either space or colon separated) | ecadbdda5a1529c58a1e9e09828d70e4 |
The SHA1 Thumbprint (hex values can also be either space or colon separated) | 34a929226ae0819f2ec14b4a3d904f801cbb150d |
If not specified, any certificate trusted by the machine is accepted.
Use '*' to signify to accept all certificates. Note that this is not recommended due to security concerns.
This section provides a complete list of the Logging properties you can configure in the connection string for this provider.
Property | Description |
Verbosity | The verbosity level that determines the amount of detail included in the log file. |
The verbosity level that determines the amount of detail included in the log file.
string
"1"
The verbosity level determines the amount of detail that the Cloud reports to the Logfile. Verbosity levels from 1 to 5 are supported. These are detailed in the Logging page.
This section provides a complete list of the Schema properties you can configure in the connection string for this provider.
Property | Description |
BrowsableSchemas | This property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC. |
This property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC.
string
""
Listing the schemas from databases can be expensive. Providing a list of schemas in the connection string improves the performance.
This section provides a complete list of the Miscellaneous properties you can configure in the connection string for this provider.
Property | Description |
CustomizeDateFormat | Configure the Date format. |
ApplicationIntent | Expresses the client application's request to be directed either to a read-write or read-only version of an availability group database. |
EnableTransaction | Determines whether transactions are enabled. |
MaxRows | Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses. |
Timeout | The value in seconds until the timeout error is thrown, canceling the operation. |
Configure the Date format.
string
""
The Date format can be customized by this property.
Expresses the client application's request to be directed either to a read-write or read-only version of an availability group database.
string
"ReadWrite"
To use read-only routing, a client must use an application intent of read-only in the connection string when connecting to the availability group listener. Without the read-only application intent, connections to the availability group listener are directed to the database on the primary replica.
ApplicationIntent allows you to connect to a read-only secondary when connecting to an Availability Group Listener.
Determines whether transactions are enabled.
bool
true
Determines whether transactions are enabled. When set to false, any operation that would involve a transaction is treated as a no-op. Serverless SQL pools do not support transactions, so this property is required to be false when working with tools that utilize transactions. Dedicated SQL pools do support transactions, so this option can be enabled if transaction support is required.
Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses.
int
-1
Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses.
The value in seconds until the timeout error is thrown, canceling the operation.
int
60
If Timeout = 0, operations do not time out. The operations run until they complete successfully or until they encounter an error condition.
If Timeout expires and the operation is not yet complete, the Cloud throws an exception.