<?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: Run JDBC Query in Developers</title>
    <link>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/538830#M24</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/260035"&gt;@danielziv&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does this help? It is from a great SGF 2019 paper that will be published soon. A friend of mine is writing it.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;caslib clibTera sessref=mysess 
                    datasource=(srctype="jdbc", 
                                       classpath="/opt/teradata/client/JDBC", 
                                       driverclass="com.teradata.jdbc.TeraDriver",
                                       URL="jdbc:teradata://teradata.sas.com",
                                       username="teraUser", 
                                       password="TeraUser1", 
                                       schema="db");

proc cas;
     session mysess;
     action save / caslib="clibTera" name="my2016Cars"
        table={caslib="clibTera" name="mycars"
                   vars={“make”}
                   where=”year = 2016”};
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I will add the link to the paper when it is published.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best wishes,&lt;/P&gt;
&lt;P&gt;Jeff&lt;/P&gt;</description>
    <pubDate>Tue, 26 Feb 2019 21:57:17 GMT</pubDate>
    <dc:creator>JBailey</dc:creator>
    <dc:date>2019-02-26T21:57:17Z</dc:date>
    <item>
      <title>Run JDBC Query</title>
      <link>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/532971#M23</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I currently run on a free trial of SAS Viya and wish to verify that I can query my DB before we purchase.&lt;/P&gt;&lt;P&gt;I wish to connect via JDBC and can not find a full working example of a select statement online.&lt;/P&gt;&lt;P&gt;Can someone please assist?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attached below the example I've written by documentation I found online&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;cas casauto;

caslib jdcaslib desc='JDBC Caslib' 
   dataSource=(srctype='jdbc',
               url="jdbc:Sqream://3.16.23.107:5001/master",
               username='sqream', 
               password='sqream'
               class="com.sqream.jdbc.SQDriver"
               classpath="/Public/SQream/SqreamJDBC.jar",
				schema="public");


proc casutil;
   list files incaslib="jdcaslib";               
   load casdata="nation" incaslib="jdcaslib" outcaslib="casuser"
        casout="DBdata_from_jdcaslib";           
   list tables incaslib="casuser";               
   contents casdata="DBdata_from_jdcaslib" incaslib="casuser";
quit;&lt;/PRE&gt;</description>
      <pubDate>Tue, 05 Feb 2019 15:45:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/532971#M23</guid>
      <dc:creator>danielziv</dc:creator>
      <dc:date>2019-02-05T15:45:46Z</dc:date>
    </item>
    <item>
      <title>Re: Run JDBC Query</title>
      <link>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/538830#M24</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/260035"&gt;@danielziv&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does this help? It is from a great SGF 2019 paper that will be published soon. A friend of mine is writing it.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;caslib clibTera sessref=mysess 
                    datasource=(srctype="jdbc", 
                                       classpath="/opt/teradata/client/JDBC", 
                                       driverclass="com.teradata.jdbc.TeraDriver",
                                       URL="jdbc:teradata://teradata.sas.com",
                                       username="teraUser", 
                                       password="TeraUser1", 
                                       schema="db");

proc cas;
     session mysess;
     action save / caslib="clibTera" name="my2016Cars"
        table={caslib="clibTera" name="mycars"
                   vars={“make”}
                   where=”year = 2016”};
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I will add the link to the paper when it is published.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best wishes,&lt;/P&gt;
&lt;P&gt;Jeff&lt;/P&gt;</description>
      <pubDate>Tue, 26 Feb 2019 21:57:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/538830#M24</guid>
      <dc:creator>JBailey</dc:creator>
      <dc:date>2019-02-26T21:57:17Z</dc:date>
    </item>
    <item>
      <title>Re: Run JDBC Query</title>
      <link>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/540025#M25</link>
      <description>&lt;P&gt;Does the example you provided do what you want?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The LOAD statement as used will load all the data into the CAS table.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Do you want to run a SQL query and then store the result of it in a CAS table? If yes I suggest you have a look at how to use &lt;A title="SAS® Viya® 3.4: FedSQL Programming for SAS® Cloud Analytic Services" href="https://go.documentation.sas.com/?docsetId=casfedsql&amp;amp;docsetTarget=titlepage.htm&amp;amp;docsetVersion=3.4&amp;amp;locale=en" target="_self"&gt;Proc FEDSQL with CAS&lt;/A&gt;.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 04 Mar 2019 13:52:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/540025#M25</guid>
      <dc:creator>BrunoMueller</dc:creator>
      <dc:date>2019-03-04T13:52:35Z</dc:date>
    </item>
    <item>
      <title>Re: Run JDBC Query</title>
      <link>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/541813#M26</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/51161"&gt;@JBailey&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Unfortunately, this suggestion did not solve our issue... we get an error of "catalog name not found" with everything we try...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 10 Mar 2019 12:48:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/541813#M26</guid>
      <dc:creator>danielziv</dc:creator>
      <dc:date>2019-03-10T12:48:50Z</dc:date>
    </item>
    <item>
      <title>Re: Run JDBC Query</title>
      <link>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/542332#M27</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/260035"&gt;@danielziv&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This entry was marked as solved because I provided a working example. The communities manager marks completed discussions as solved because it helps people who land on the page from Google. Plus, and this is huge, SAS Communities members prefer that we keep discussions to a single topic.&lt;BR /&gt;&lt;BR /&gt;Create another discussion showing the code you are using, and the error you are receiving, and I will take a look at it. Add my alias to it so that I am notified that the new topic is there.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best wishes,&lt;/P&gt;
&lt;P&gt;Jeff&lt;/P&gt;</description>
      <pubDate>Tue, 12 Mar 2019 11:26:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/Run-JDBC-Query/m-p/542332#M27</guid>
      <dc:creator>JBailey</dc:creator>
      <dc:date>2019-03-12T11:26:24Z</dc:date>
    </item>
  </channel>
</rss>

