After setting the CLASSPATH, the connection information needs to be passed in the form of a connection URL. This section provides examples of connection strings configured to use common features and functionality. You can modify and/or combine these examples to create a connection string for your environment.

Note:
  • Connection property names are case-insensitive. For example, Password is the same as password.
  • For connection properties that support string values, use the following escape sequence to specify values containing leading or trailing spaces and curly brackets: {value}. For example: User={hello } or Password={{hello}}.
jdbc:datadirect:sqlserver://servername:port;
[property=value[;...]];

Microsoft Fabric

Note: For Microsoft Fabric, only the following authentication methods are supported: Microsoft Entra ID user ID/password authentication and Microsoft Entra ID service principal authentication.
  • Microsoft Entra ID user ID/password authentication:

    This string includes the properties used to connect with the Microsoft Entra ID (Azure Active Directory) user ID and password authentication.

    jdbc:datadirect:sqlserver://myserver.database.windows:1433;
         AuthenticationMethod=activeDirectoryPassword;
         User=jsmith@mydomain.com;Password=secret;

    For more information on these properties and values, see Microsoft Entra ID authentication.

  • Microsoft Entra ID service principal authentication:

    This string includes the properties used to connect with the Microsoft Entra ID (Azure Active Directory) service principal authentication.

    jdbc:datadirect:sqlserver://myserver.database.windows:1433;
         AuthenticationMethod=activeDirectoryServicePrincipal;
         ActiveDirectoryPrincipalID=789f8b4c-7a4a-445d-6oe9;
         ActiveDirectoryPrincipalSecret=ABcdEFg/hiJkLmNOPqR01stUvW;

    For more information on these properties and values, see Microsoft Entra ID authentication.

  • Proxy server:

    This string includes the properties used to connect through a proxy server.

    jdbc:datadirect:fabric://myserver:1433;AuthenticationMethod=activeDirectoryPassword;
         ProxyHost=pserver;ProxyPassword=secret;ProxyPort=808;ProxyUser=johnSmith;
         User=jsmith@example.com;Password=secret;

    For more information on these properties and values, see Connection property descriptions.

Microsoft SQL Server

  • User ID/password authentication:

    This string includes the properties used to connect with the user ID and password authentication method.

    jdbc:datadirect:sqlserver://myserver:1433;
         AuthenticationMethod=userIdPassword;User=JSmith;
         Password=secret;

    For more information on these properties and values, see User ID/password authentication.

  • Microsoft Entra ID user ID/password authentication:

    This string includes the properties used to connect with the Microsoft Entra ID (Azure Active Directory) user ID and password authentication.

    jdbc:datadirect:sqlserver://myserver.database.windows:1433;
         AuthenticationMethod=activeDirectoryPassword;
         User=jsmith@mydomain.com;Password=secret;

    For more information on these properties and values, see Microsoft Entra ID authentication.

  • Microsoft Entra ID service principal authentication:

    This string includes the properties used to connect with the Microsoft Entra ID (Azure Active Directory) service principal authentication.

    jdbc:datadirect:sqlserver://myserver.database.windows:1433;
         AuthenticationMethod=activeDirectoryServicePrincipal;
         ActiveDirectoryPrincipalID=789f8b4c-7a4a-445d-6oe9;
         ActiveDirectoryPrincipalSecret=ABcdEFg/hiJkLmNOPqR01stUvW;

    For more information on these properties and values, see Microsoft Entra ID authentication.

  • Microsoft Entra ID managed identity authentication:

    This string includes the properties used to connect with the Microsoft Entra ID (Azure Active Directory) managed identity authentication.

    jdbc:datadirect:sqlserver://myserver.database.windows:1433;
         AuthenticationMethod=ActiveDirectoryManagedIdentity;
         User=f4f42d67-6857-4d58-a510-83a3dc082469;

    For more information on these properties and values, see Microsoft Entra ID authentication.

  • Kerberos authentication:

    This string includes the properties used to connect with Kerberos authentication.

    jdbc:datadirect:sqlserver://myserver:1433;
         DatabaseName=sqlserverDB;AuthenticationMethod=kerberos;
         ServicePrincipalName=MSSQLSvc/myserver.example.com:1433@EXAMPLE.COM;

    For more information on these properties and values, see Kerberos authentication.

  • NTLM authentication:

    This string includes the properties used to connect with NTLM authentication with credentials.

    jdbc:datadirect:sqlserver://myserver:1433;AuthenticationMethod=ntlm; 
         Domain=sso3;User=jsmith;Password=secret;

    This string includes the properties used to connect with NTLM authentication without credentials (Windows only).

    jdbc:datadirect:sqlserver://myserver:1433;AuthenticationMethod=ntlm; 
         DatabaseName=test;LoadLibraryPath=C:\DataDirect\lib;User=jsmith;
         Password=secret;

    For more information on these properties and values, see NTLM authentication.

  • Access token authentication:

    This string includes the properties used to connect with access token authentication.

    jdbc:datadirect:sqlserver://myserver:1433;AuthenticationMethod=auto;
         AccessToken=abc12cd34efg5678h9ij87klm6543no32pqr10;

    For more information on these properties and values, see Access token authentication.

  • Proxy server:

    This string includes the properties used to connect through a proxy server.

    jdbc:datadirect:sqlserver://myserver:1433;AuthenticationMethod=userIdPassword;
         ProxyHost=pserver;ProxyPassword=secret;ProxyPort=808;ProxyUser=johnSmith;
         User=jsmith@example.com;Password=secret;

    For more information on these properties and values, see Connection property descriptions.