<?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: Comparing SAS data with Oracle/Terradata/SQL data in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585727#M167108</link>
    <description>&lt;P&gt;Upload your 1000 account numbers into a temporary table in the DBMS and use that for a join there (using explicit passthrough). Then download the results to SAS.&lt;/P&gt;</description>
    <pubDate>Tue, 03 Sep 2019 09:00:27 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2019-09-03T09:00:27Z</dc:date>
    <item>
      <title>Comparing SAS data with Oracle/Terradata/SQL data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585724#M167107</link>
      <description>&lt;P&gt;I have a dataset in SAS with 1000 observations containing account numbers and I have another table in Oracle/Terradata/SQL with trillions of records(cannot be downloaded) containing the transaction details of those account numbers. Now, I want to get the transaction details of those 1000 account numbers using SAS programming.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Note: The comparison of data must be done without bringing the data from other server to SAS.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can anyone help?&lt;/P&gt;&lt;P&gt;If not possible to write the code, at least try filling me with logic&lt;/P&gt;</description>
      <pubDate>Tue, 03 Sep 2019 08:57:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585724#M167107</guid>
      <dc:creator>Siddhu</dc:creator>
      <dc:date>2019-09-03T08:57:36Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing SAS data with Oracle/Terradata/SQL data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585727#M167108</link>
      <description>&lt;P&gt;Upload your 1000 account numbers into a temporary table in the DBMS and use that for a join there (using explicit passthrough). Then download the results to SAS.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Sep 2019 09:00:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585727#M167108</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2019-09-03T09:00:27Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing SAS data with Oracle/Terradata/SQL data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585740#M167114</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/231696"&gt;@Siddhu&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Besides of what&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/11562"&gt;@Kurt_Bremser&lt;/a&gt;&amp;nbsp;proposes a volume as low as a 1000 accounts would also allow to populate a SAS macro variable with these numbers and then use this macro variable in a where clause querying the Oracle table. The where clause will then execute within Oracle and you only transfer matching transaction to SAS.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Code like below should do this job.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql noprint;
  select cats("'",account_no,"'") into :account_no_list separated by ','
  from SASTable
  ;
  create table matching_transactions as
    select *
    from OracleTable
    where account_no in (&amp;amp;account_no_list)
  ;
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Sep 2019 10:06:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585740#M167114</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2019-09-03T10:06:51Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing SAS data with Oracle/Terradata/SQL data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585761#M167130</link>
      <description>&lt;P&gt;Just small doubt bro.&lt;/P&gt;&lt;P&gt;when we set a connection to Oracle using pass-through facility then the connection to SAS will be lost, then, will the macro variable be able to get executed with where statement when connected to oracle?&lt;/P&gt;&lt;P&gt;I know that macro variables are processed at compile time but just need clarity&amp;nbsp;&lt;/P&gt;&lt;P&gt;And, thanks so much for the response&lt;/P&gt;</description>
      <pubDate>Tue, 03 Sep 2019 11:07:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585761#M167130</guid>
      <dc:creator>Siddhu</dc:creator>
      <dc:date>2019-09-03T11:07:11Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing SAS data with Oracle/Terradata/SQL data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585806#M167149</link>
      <description>&lt;P&gt;The SAS macro variable will resolve on the SAS side. The syntax SAS will send to Oracle for execution will have the content of the macro variable in it (all account numbers in the where condition).&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Oracle accepts SQL code of up to 32KB so 1000 account numbers shouldn't be an issue.&lt;/P&gt;
&lt;P&gt;You can use the SAS macro variable in both implicit and explicit pass-through code. It doesn't make a difference because as said - the macro variable gets resolved before SAS even sends any code to Oracle for execution.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Sep 2019 13:06:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/585806#M167149</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2019-09-03T13:06:35Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing SAS data with Oracle/Terradata/SQL data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/586004#M167225</link>
      <description>Thanks so much. You are helpful</description>
      <pubDate>Wed, 04 Sep 2019 05:49:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Comparing-SAS-data-with-Oracle-Terradata-SQL-data/m-p/586004#M167225</guid>
      <dc:creator>Siddhu</dc:creator>
      <dc:date>2019-09-04T05:49:18Z</dc:date>
    </item>
  </channel>
</rss>

