<?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: Adding tables based on the same struture one after another in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578448#M13351</link>
    <description>&lt;P&gt;thank you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would need an example to understand how to use this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Let's say all tables have the following name, ending with a number from 1 to n:&lt;/P&gt;&lt;P&gt;Prod_Week_1 to Prod_Week_n&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I guess I now have to write :&lt;/P&gt;&lt;P&gt;Prod_Week_:&lt;/P&gt;&lt;P&gt;into the code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data want;&lt;/P&gt;&lt;P&gt;set&amp;nbsp;Prod_Week_: ;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is this correct?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the second proposed solution seems more complicated to me (I'm new to SAS), and I don't understand how to write this down in the code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;PY&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>Thu, 01 Aug 2019 15:03:37 GMT</pubDate>
    <dc:creator>PierreYvesILY</dc:creator>
    <dc:date>2019-08-01T15:03:37Z</dc:date>
    <item>
      <title>Adding tables based on the same struture one after another</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578377#M13345</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have n tables (&amp;gt;50)&amp;nbsp;with the same variable names, and want to add them after another.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I want this result:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Xiple_Dataset_Fusion2.PNG" style="width: 186px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/31461i8151A8DFD3087A95/image-size/large?v=v2&amp;amp;px=999" role="button" title="Xiple_Dataset_Fusion2.PNG" alt="Xiple_Dataset_Fusion2.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;what should I do?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks in advance,&lt;/P&gt;&lt;P&gt;PY&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2019 12:49:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578377#M13345</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-08-01T12:49:11Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables based on the same struture one after another</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578380#M13346</link>
      <description>&lt;P&gt;Use them in a single set statement, in the wanted order:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
set
  set1
  set2
  ....
  set50
;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 01 Aug 2019 12:59:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578380#M13346</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2019-08-01T12:59:31Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables based on the same struture one after another</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578390#M13348</link>
      <description>&lt;P&gt;hello,&lt;/P&gt;&lt;P&gt;thanks.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the methods I use, but I hoped there would be something more practical to avoid typing all tables names - and that I would just not be aware of.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Have a nice day,&lt;/P&gt;&lt;P&gt;PY&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2019 13:25:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578390#M13348</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-08-01T13:25:08Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables based on the same struture one after another</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578435#M13350</link>
      <description>&lt;P&gt;If the tables share a common prefix, you can use the colon wildcard; or if you have any other rule, you can use a select into from dictionary.tables to create a macro variable that holds the table names for the set statement.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2019 14:41:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578435#M13350</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2019-08-01T14:41:08Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables based on the same struture one after another</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578448#M13351</link>
      <description>&lt;P&gt;thank you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would need an example to understand how to use this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Let's say all tables have the following name, ending with a number from 1 to n:&lt;/P&gt;&lt;P&gt;Prod_Week_1 to Prod_Week_n&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I guess I now have to write :&lt;/P&gt;&lt;P&gt;Prod_Week_:&lt;/P&gt;&lt;P&gt;into the code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data want;&lt;/P&gt;&lt;P&gt;set&amp;nbsp;Prod_Week_: ;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is this correct?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the second proposed solution seems more complicated to me (I'm new to SAS), and I don't understand how to write this down in the code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;PY&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>Thu, 01 Aug 2019 15:03:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578448#M13351</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-08-01T15:03:37Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables based on the same struture one after another</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578458#M13353</link>
      <description>&lt;P&gt;#1 is exactly what I was hinting at with wildcards.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;#2 will look like this:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql noprint; /* we don't need print output */
select catx('.',libname,memname) into :dsnames separated by ' '
from dictionary.tables
where libname = "XXXX" and /* add further suitable conditions here */
;
quit;

data want;
set &amp;amp;dsnames.;
run; &lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 01 Aug 2019 15:13:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578458#M13353</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2019-08-01T15:13:14Z</dc:date>
    </item>
    <item>
      <title>Re: Adding tables based on the same struture one after another</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578468#M13354</link>
      <description>&lt;P&gt;Thanks a lot.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'll be able to process the 52 files tomorrow now...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Have a nice evening,&lt;/P&gt;&lt;P&gt;PY&lt;/P&gt;</description>
      <pubDate>Thu, 01 Aug 2019 15:23:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Adding-tables-based-on-the-same-struture-one-after-another/m-p/578468#M13354</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-08-01T15:23:05Z</dc:date>
    </item>
  </channel>
</rss>

