<?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: Merging multiple dataset in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Merging-multiple-dataset/m-p/10737#M1084</link>
    <description>Something like this, untested code,&lt;BR /&gt;
&lt;BR /&gt;
PROC SQL;&lt;BR /&gt;
CREATE TABLE abc AS&lt;BR /&gt;
SELECT a.*, b.join_date, c.term_date&lt;BR /&gt;
FROM a, b, c&lt;BR /&gt;
WHERE a.id=b.id AND a.id=c.id;&lt;BR /&gt;
&lt;BR /&gt;
That will do an inner join keeping all the columns from a and just the respective dates from b and c.  A left join would be similar; you can find the specifics in the SQL manual.</description>
    <pubDate>Tue, 15 Feb 2011 20:36:59 GMT</pubDate>
    <dc:creator>Doc_Duke</dc:creator>
    <dc:date>2011-02-15T20:36:59Z</dc:date>
    <item>
      <title>Merging multiple dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Merging-multiple-dataset/m-p/10735#M1082</link>
      <description>Hi,&lt;BR /&gt;
&lt;BR /&gt;
Is it possible to merge multiple datasets in one proc sql.&lt;BR /&gt;
&lt;BR /&gt;
I have 3 tables.  Each of them have same id but different join_date and term_date.  I want a dataset which holds the data for each id join_date and term_date.&lt;BR /&gt;
&lt;BR /&gt;
I tried data step, but it doesn't take the multiple records on the same id value.&lt;BR /&gt;
&lt;BR /&gt;
Thanks in advance,&lt;BR /&gt;
Sandhya.</description>
      <pubDate>Tue, 15 Feb 2011 19:26:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Merging-multiple-dataset/m-p/10735#M1082</guid>
      <dc:creator>Sandhya</dc:creator>
      <dc:date>2011-02-15T19:26:13Z</dc:date>
    </item>
    <item>
      <title>Re: Merging multiple dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Merging-multiple-dataset/m-p/10736#M1083</link>
      <description>It's best to share whatever code you have tried, preferably in a SAS-generated log output with all statements revealed (not just your source code window).&lt;BR /&gt;
&lt;BR /&gt;
Also, share a data-sample, as well - both for the INPUT side and the expected/desired OUTPUT side, listed in a post-reply.&lt;BR /&gt;
&lt;BR /&gt;
Scott Barry&lt;BR /&gt;
SBBWorks, Inc.</description>
      <pubDate>Tue, 15 Feb 2011 20:34:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Merging-multiple-dataset/m-p/10736#M1083</guid>
      <dc:creator>sbb</dc:creator>
      <dc:date>2011-02-15T20:34:12Z</dc:date>
    </item>
    <item>
      <title>Re: Merging multiple dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Merging-multiple-dataset/m-p/10737#M1084</link>
      <description>Something like this, untested code,&lt;BR /&gt;
&lt;BR /&gt;
PROC SQL;&lt;BR /&gt;
CREATE TABLE abc AS&lt;BR /&gt;
SELECT a.*, b.join_date, c.term_date&lt;BR /&gt;
FROM a, b, c&lt;BR /&gt;
WHERE a.id=b.id AND a.id=c.id;&lt;BR /&gt;
&lt;BR /&gt;
That will do an inner join keeping all the columns from a and just the respective dates from b and c.  A left join would be similar; you can find the specifics in the SQL manual.</description>
      <pubDate>Tue, 15 Feb 2011 20:36:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Merging-multiple-dataset/m-p/10737#M1084</guid>
      <dc:creator>Doc_Duke</dc:creator>
      <dc:date>2011-02-15T20:36:59Z</dc:date>
    </item>
  </channel>
</rss>

