<?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: Need help understanding proc sql &amp;quot;Connect to &amp;quot; in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Need-help-understanding-proc-sql-quot-Connect-to-quot/m-p/451470#M113832</link>
    <description>I may add that the reason id like to do this, is that the process takes a very long time on PC. When i do this with a dataset on server and leftjoin work i save about 97% time.&lt;BR /&gt;&lt;BR /&gt;If you cant solve this problem, but know another way to calculate my merge on server this is also greatly appreciated.</description>
    <pubDate>Thu, 05 Apr 2018 11:47:20 GMT</pubDate>
    <dc:creator>Shawnty</dc:creator>
    <dc:date>2018-04-05T11:47:20Z</dc:date>
    <item>
      <title>Need help understanding proc sql "Connect to "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Need-help-understanding-proc-sql-quot-Connect-to-quot/m-p/451468#M113831</link>
      <description>&lt;P&gt;hello,&lt;BR /&gt;&lt;BR /&gt;I have a&amp;nbsp; question about running connect to option&amp;nbsp; in PROC SQL. Currently im able to do calculations as such:&lt;BR /&gt;proc sql feedback;&lt;BR /&gt;connect to odbc as DB (dsn="[name]");&lt;BR /&gt;create table work.Want as select * from connection to DB&lt;BR /&gt;(&lt;BR /&gt;select t1.*,&lt;BR /&gt;divide(t2.A,t2.B) as ABC&lt;BR /&gt;from DB.[Scheme].[Have_on_server] AS t1&lt;BR /&gt;left join work.[have_in_work] AS t2 on t1.A=t2.A&lt;BR /&gt;);&lt;BR /&gt;disconnect from &lt;SPAN&gt;DB&amp;nbsp;&lt;/SPAN&gt;;&lt;BR /&gt;quit;&lt;BR /&gt;Where i take a dataset from server, left join a dataset from my work and put the dataset in my work.&lt;BR /&gt;&lt;BR /&gt;But if i instead take a dataset from work and left join a dataset on server, this does not work. Does anyone have a clue as of why it isnt working?&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;proc sql feedback;&lt;BR /&gt;connect to odbc as DB (dsn="[name]");&lt;BR /&gt;create table work.Want as select * from connection to DB&lt;BR /&gt;(&lt;BR /&gt;select t1.*,&lt;BR /&gt;divide(t2.A,t2.B) as ABC&lt;BR /&gt;from work.[Have_in_work] as t1&lt;BR /&gt;left join DB.[Scheme].[Have_on_server] AS t2 on&lt;BR /&gt;(t1.A=t2.A)&lt;BR /&gt;);&lt;BR /&gt;disconnect from &lt;SPAN&gt;DB&amp;nbsp;&lt;/SPAN&gt;;&lt;BR /&gt;quit;&lt;/P&gt;</description>
      <pubDate>Thu, 05 Apr 2018 11:45:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Need-help-understanding-proc-sql-quot-Connect-to-quot/m-p/451468#M113831</guid>
      <dc:creator>Shawnty</dc:creator>
      <dc:date>2018-04-05T11:45:25Z</dc:date>
    </item>
    <item>
      <title>Re: Need help understanding proc sql "Connect to "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Need-help-understanding-proc-sql-quot-Connect-to-quot/m-p/451470#M113832</link>
      <description>I may add that the reason id like to do this, is that the process takes a very long time on PC. When i do this with a dataset on server and leftjoin work i save about 97% time.&lt;BR /&gt;&lt;BR /&gt;If you cant solve this problem, but know another way to calculate my merge on server this is also greatly appreciated.</description>
      <pubDate>Thu, 05 Apr 2018 11:47:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Need-help-understanding-proc-sql-quot-Connect-to-quot/m-p/451470#M113832</guid>
      <dc:creator>Shawnty</dc:creator>
      <dc:date>2018-04-05T11:47:20Z</dc:date>
    </item>
    <item>
      <title>Re: Need help understanding proc sql "Connect to "</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Need-help-understanding-proc-sql-quot-Connect-to-quot/m-p/451479#M113835</link>
      <description>&lt;P&gt;Hi Shawnty,&lt;/P&gt;
&lt;P&gt;there a tons of similar questions on the forum, do a search and hopefully you will get some input.&lt;/P&gt;
&lt;P&gt;Basics: CONNECT TO works soly in the realms of the external data source, everything sent there have no clues of your local environment.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So the trick is merge these worlds together somehow.&lt;/P&gt;
&lt;P&gt;Techniques include uploading your local data set to the server as a volatile table (similar to a SAS work table), or by performing the join using a libname reference to your server table, then could use the DBKEY= option, and if local data is small enough SAS may transform the&amp;nbsp;join key to a WHERE clause sent to the RDBMS table.&lt;/P&gt;</description>
      <pubDate>Thu, 05 Apr 2018 12:18:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Need-help-understanding-proc-sql-quot-Connect-to-quot/m-p/451479#M113835</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2018-04-05T12:18:16Z</dc:date>
    </item>
  </channel>
</rss>

