<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Databricks connection error in viya 4 in SAS Studio</title>
    <link>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947226#M11356</link>
    <description>&lt;P&gt;This error looks to me like it can't find the JDBC driver.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've never tried this myself so can't really be of further help. If you don't get sufficient answers here in the forum then contact SAS TechSupport directly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Below what Copilot suggested - which might or might not be correct.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="content user-select-text" tabindex="0" aria-description="" aria-label="Sent by Copilot: To connect SAS to Databricks on AWS using the `LIBNAME` statement, you can use the JDBC interface. Here's an example of how you might set this up:

```sas
libname mydblib jdbc 
    classpath=&amp;quot;/path/to/jdbc/driver&amp;quot; 
    class=&amp;quot;cdata.jdbc.databricks.DatabricksDriver&amp;quot; 
    URL=&amp;quot;jdbc:databricks://&amp;lt;hostname&amp;gt;:443;httpPath='/sql/1.0/warehouses/&amp;lt;warehouse_id&amp;gt;';ssl=1;AuthMech=3;UID=&amp;lt;your_username&amp;gt;;PWD=&amp;lt;your_password&amp;gt;&amp;quot;;
```

Replace the placeholders with your actual Databricks server details:
- `&amp;lt;hostname&amp;gt;`: Your Databricks server name.
- `&amp;lt;warehouse_id&amp;gt;`: The ID of your Databricks SQL warehouse.
- `&amp;lt;your_username&amp;gt;`: Your Databricks username.
- `&amp;lt;your_password&amp;gt;`: Your Databricks password.

Make sure the JDBC driver is correctly installed and the classpath points to the location of the driver.

If you encounter any issues, double-check the connection properties and ensure they are correctly formatted. For example, the `httpPath` should not have single quotes around it, and `ssl` should be set to `1` if using SSL[^1^](https://communities.sas.com/t5/Moving-to-SAS-Viya/Establishing-a-libname-connection-to-Databricks-from-SAS-Viya-4/td-p/937611)[^2^](https://www.databricks.com/blog/2022/03/16/how-to-speed-up-data-flow-between-databricks-and-sas.html).

Feel free to ask if you need further assistance or run into any specific errors!"&gt;
&lt;DIV class="ac-container ac-adaptiveCard"&gt;
&lt;DIV class="ac-textBlock"&gt;
&lt;P&gt;To connect SAS to Databricks on AWS using the &lt;CODE&gt;LIBNAME&lt;/CODE&gt; statement, you can use the JDBC interface. Here’s an example of how you might set this up:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class="language-sas"&gt;&lt;SPAN class="hljs-keyword"&gt;libname&lt;/SPAN&gt; mydblib jdbc 
    classpath=&lt;SPAN class="hljs-string"&gt;"/path/to/jdbc/driver"&lt;/SPAN&gt; 
    class=&lt;SPAN class="hljs-string"&gt;"cdata.jdbc.databricks.DatabricksDriver"&lt;/SPAN&gt; 
    URL=&lt;SPAN class="hljs-string"&gt;"jdbc:databricks://&amp;lt;hostname&amp;gt;:443;httpPath='/sql/1.0/warehouses/&amp;lt;warehouse_id&amp;gt;';ssl=1;AuthMech=3;UID=&amp;lt;your_username&amp;gt;;PWD=&amp;lt;your_password&amp;gt;"&lt;/SPAN&gt;;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Replace the placeholders with your actual Databricks server details:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;CODE&gt;&amp;lt;hostname&amp;gt;&lt;/CODE&gt;: Your Databricks server name.&lt;/LI&gt;
&lt;LI&gt;&lt;CODE&gt;&amp;lt;warehouse_id&amp;gt;&lt;/CODE&gt;: The ID of your Databricks SQL warehouse.&lt;/LI&gt;
&lt;LI&gt;&lt;CODE&gt;&amp;lt;your_username&amp;gt;&lt;/CODE&gt;: Your Databricks username.&lt;/LI&gt;
&lt;LI&gt;&lt;CODE&gt;&amp;lt;your_password&amp;gt;&lt;/CODE&gt;: Your Databricks password.&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;Make sure the JDBC driver is correctly installed and the classpath points to the location of the driver.&lt;/P&gt;
&lt;P&gt;If you encounter any issues, double-check the connection properties and ensure they are correctly formatted.&amp;nbsp;For example, the httpPath should not have single quotes around it, and ssl should be set to 1 if using SSL.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://communities.sas.com/t5/Moving-to-SAS-Viya/Establishing-a-libname-connection-to-Databricks-from-SAS-Viya-4/td-p/937611" target="_self"&gt;Establishing a libname connection to Databricks from SAS Viya 4 on AWS&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.databricks.com/blog/2022/03/16/how-to-speed-up-data-flow-between-databricks-and-sas.html" target="_self"&gt;How to Speed Up Data Flow Between Databricks and SAS&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;</description>
    <pubDate>Sat, 12 Oct 2024 23:52:02 GMT</pubDate>
    <dc:creator>Patrick</dc:creator>
    <dc:date>2024-10-12T23:52:02Z</dc:date>
    <item>
      <title>Databricks connection error in viya 4</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947094#M11351</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We are getting issue while connection databricks in viya4 , connection is establishing successfully with cas lib but while using following libname we are getting system error trust store. Please help me out to resolve this.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ERROR: Error trying to establish connection: System error: problem accessing trust store&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;ERROR: Error in the LIBNAME statement.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;libname statement&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;libname spkdb spark&lt;BR /&gt;user='token'&lt;BR /&gt;password='xxxxxxxxxxxxxx'&lt;BR /&gt;platform='databricks'&lt;BR /&gt;server='xxxxxxxxxxxxxxxxxxxxxxxxxxx'&lt;BR /&gt;database='xxxxx'&lt;BR /&gt;httppath='/sql/1.0/warehouses/xxxxxxx'&lt;BR /&gt;properties='QueryPassthrough=true';'DefaultColumnSize=1024';'ssl=true';&lt;BR /&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Chethandeepak_0-1728632479047.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/101133i2610BF913FD9F98D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Chethandeepak_0-1728632479047.png" alt="Chethandeepak_0-1728632479047.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2024 07:44:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947094#M11351</guid>
      <dc:creator>Chethandeepak</dc:creator>
      <dc:date>2024-10-11T07:44:27Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks connection error in viya 4</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947096#M11352</link>
      <description>&lt;P&gt;Just as an observation: Wouldn't below semicolons not need to be within the single quotes so that the first one doesn't terminate the SAS libname statement?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Patrick_0-1728633048402.png" style="width: 620px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/101134i0E87E8593B713F78/image-dimensions/620x31?v=v2" width="620" height="31" role="button" title="Patrick_0-1728633048402.png" alt="Patrick_0-1728633048402.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2024 07:51:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947096#M11352</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2024-10-11T07:51:48Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks connection error in viya 4</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947109#M11353</link>
      <description>&lt;P&gt;Hi ,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Tried using correct syntax but still getting same error&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Chethandeepak_0-1728639617815.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/101136i9DF19A60428F3BB5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Chethandeepak_0-1728639617815.png" alt="Chethandeepak_0-1728639617815.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Chethandeepak_1-1728639687131.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/101137i78D971ABBFEB06B2/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Chethandeepak_1-1728639687131.png" alt="Chethandeepak_1-1728639687131.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2024 09:41:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947109#M11353</guid>
      <dc:creator>Chethandeepak</dc:creator>
      <dc:date>2024-10-11T09:41:59Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks connection error in viya 4</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947111#M11354</link>
      <description>&lt;P&gt;I've never done it so don't really know. But just based on the documentation found &lt;A href="https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/acreldb/p1qzm30adels9wn1oze9mgyc5pwc.htm" target="_self"&gt;here&lt;/A&gt;&amp;nbsp;it looks to me that at least some of the connection info needs to be passed via parameter URL.&lt;/P&gt;
&lt;PRE&gt;Connecting to Databricks in Microsoft Azure
This example accesses Spark data in Databricks on Microsoft Azure. The Databricks JDBC driver is recommended for accessing Spark data in Databricks.

libname spkdbk spark classpath='/JAR-path'
   driverclass="com.databricks.client.jdbc.Driver"
   bulkload=no
   url=' jdbc:spark://server:port/schema;transportMode=http;ssl=1;HTTPPath=myHttpPath;
   AuthMech=3;defaultStringColumnLength=255;useNativeQuery=1;&amp;lt;options&amp;gt;'
   user=token
   password=mytoken
 ; &lt;/PRE&gt;</description>
      <pubDate>Fri, 11 Oct 2024 10:05:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947111#M11354</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2024-10-11T10:05:33Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks connection error in viya 4</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947115#M11355</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have tried suggested libname but it is for azure and im trying in aws databricks how tried with libname getting&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ERROR: Error trying to establish connection: java.lang.ClassNotFoundException: com.databricks.client.jdbc.Driver&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Chethandeepak_0-1728643000681.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/101138iC670535559646A47/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Chethandeepak_0-1728643000681.png" alt="Chethandeepak_0-1728643000681.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2024 10:36:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947115#M11355</guid>
      <dc:creator>Chethandeepak</dc:creator>
      <dc:date>2024-10-11T10:36:57Z</dc:date>
    </item>
    <item>
      <title>Re: Databricks connection error in viya 4</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947226#M11356</link>
      <description>&lt;P&gt;This error looks to me like it can't find the JDBC driver.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've never tried this myself so can't really be of further help. If you don't get sufficient answers here in the forum then contact SAS TechSupport directly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Below what Copilot suggested - which might or might not be correct.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="content user-select-text" tabindex="0" aria-description="" aria-label="Sent by Copilot: To connect SAS to Databricks on AWS using the `LIBNAME` statement, you can use the JDBC interface. Here's an example of how you might set this up:

```sas
libname mydblib jdbc 
    classpath=&amp;quot;/path/to/jdbc/driver&amp;quot; 
    class=&amp;quot;cdata.jdbc.databricks.DatabricksDriver&amp;quot; 
    URL=&amp;quot;jdbc:databricks://&amp;lt;hostname&amp;gt;:443;httpPath='/sql/1.0/warehouses/&amp;lt;warehouse_id&amp;gt;';ssl=1;AuthMech=3;UID=&amp;lt;your_username&amp;gt;;PWD=&amp;lt;your_password&amp;gt;&amp;quot;;
```

Replace the placeholders with your actual Databricks server details:
- `&amp;lt;hostname&amp;gt;`: Your Databricks server name.
- `&amp;lt;warehouse_id&amp;gt;`: The ID of your Databricks SQL warehouse.
- `&amp;lt;your_username&amp;gt;`: Your Databricks username.
- `&amp;lt;your_password&amp;gt;`: Your Databricks password.

Make sure the JDBC driver is correctly installed and the classpath points to the location of the driver.

If you encounter any issues, double-check the connection properties and ensure they are correctly formatted. For example, the `httpPath` should not have single quotes around it, and `ssl` should be set to `1` if using SSL[^1^](https://communities.sas.com/t5/Moving-to-SAS-Viya/Establishing-a-libname-connection-to-Databricks-from-SAS-Viya-4/td-p/937611)[^2^](https://www.databricks.com/blog/2022/03/16/how-to-speed-up-data-flow-between-databricks-and-sas.html).

Feel free to ask if you need further assistance or run into any specific errors!"&gt;
&lt;DIV class="ac-container ac-adaptiveCard"&gt;
&lt;DIV class="ac-textBlock"&gt;
&lt;P&gt;To connect SAS to Databricks on AWS using the &lt;CODE&gt;LIBNAME&lt;/CODE&gt; statement, you can use the JDBC interface. Here’s an example of how you might set this up:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class="language-sas"&gt;&lt;SPAN class="hljs-keyword"&gt;libname&lt;/SPAN&gt; mydblib jdbc 
    classpath=&lt;SPAN class="hljs-string"&gt;"/path/to/jdbc/driver"&lt;/SPAN&gt; 
    class=&lt;SPAN class="hljs-string"&gt;"cdata.jdbc.databricks.DatabricksDriver"&lt;/SPAN&gt; 
    URL=&lt;SPAN class="hljs-string"&gt;"jdbc:databricks://&amp;lt;hostname&amp;gt;:443;httpPath='/sql/1.0/warehouses/&amp;lt;warehouse_id&amp;gt;';ssl=1;AuthMech=3;UID=&amp;lt;your_username&amp;gt;;PWD=&amp;lt;your_password&amp;gt;"&lt;/SPAN&gt;;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Replace the placeholders with your actual Databricks server details:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;CODE&gt;&amp;lt;hostname&amp;gt;&lt;/CODE&gt;: Your Databricks server name.&lt;/LI&gt;
&lt;LI&gt;&lt;CODE&gt;&amp;lt;warehouse_id&amp;gt;&lt;/CODE&gt;: The ID of your Databricks SQL warehouse.&lt;/LI&gt;
&lt;LI&gt;&lt;CODE&gt;&amp;lt;your_username&amp;gt;&lt;/CODE&gt;: Your Databricks username.&lt;/LI&gt;
&lt;LI&gt;&lt;CODE&gt;&amp;lt;your_password&amp;gt;&lt;/CODE&gt;: Your Databricks password.&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;Make sure the JDBC driver is correctly installed and the classpath points to the location of the driver.&lt;/P&gt;
&lt;P&gt;If you encounter any issues, double-check the connection properties and ensure they are correctly formatted.&amp;nbsp;For example, the httpPath should not have single quotes around it, and ssl should be set to 1 if using SSL.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://communities.sas.com/t5/Moving-to-SAS-Viya/Establishing-a-libname-connection-to-Databricks-from-SAS-Viya-4/td-p/937611" target="_self"&gt;Establishing a libname connection to Databricks from SAS Viya 4 on AWS&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.databricks.com/blog/2022/03/16/how-to-speed-up-data-flow-between-databricks-and-sas.html" target="_self"&gt;How to Speed Up Data Flow Between Databricks and SAS&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Sat, 12 Oct 2024 23:52:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Databricks-connection-error-in-viya-4/m-p/947226#M11356</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2024-10-12T23:52:02Z</dc:date>
    </item>
  </channel>
</rss>

