<?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: How to automate? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137311#M27758</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can some one help me through this code plsss&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 27 Jan 2015 06:32:38 GMT</pubDate>
    <dc:creator>Ravikumarkummari</dc:creator>
    <dc:date>2015-01-27T06:32:38Z</dc:date>
    <item>
      <title>How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137302#M27749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hiiiii all,&lt;BR /&gt; solve this query &lt;BR /&gt; suppose some insurance data is availabe in D:\kumar folder.&lt;BR /&gt; in that year wise information is there. in folders ex:2003-2013(these are 10 folders)&lt;BR /&gt; again in each folder sub folders are there for month wise january-june.&lt;SPAN class="text_exposed_show"&gt;&lt;BR /&gt; and in each month some datasets are there respective to that month.&lt;BR /&gt; example in january information is in the form of datasets like(data_a, data_b, data_c) same type of data sets are availabe in all months.&lt;BR /&gt; now you should got my point.&lt;BR /&gt; (2003)-(january-june), (data_a,data_b,data_c)&lt;BR /&gt; -&lt;BR /&gt; -&lt;BR /&gt; -&lt;BR /&gt; -&lt;BR /&gt; -&lt;BR /&gt; 2013-,(january-june) , (data_a,data_b,data_c)&lt;BR /&gt; now i have question that i need final output is "final_data_a" , "final_data_b", "final_data_c"&lt;BR /&gt; the final_data_a is contain all the ("data_a") datasets in all over 10years years. i.e. merging of all 2003-2013 (january-june) data_a(dataset)&lt;BR /&gt; how to automate this code can any one explain by using sas-macros&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="UFILikeLink" data-ft="{&amp;quot;tn&amp;quot;:&amp;quot;?&amp;quot;}" data-reactid=".24" href="https://www.facebook.com/" title="Unlike this"&gt;&lt;SPAN data-reactid=".24.1"&gt;U&lt;/SPAN&gt;&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 04:40:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137302#M27749</guid>
      <dc:creator>venkatnaveen</dc:creator>
      <dc:date>2015-01-25T04:40:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137303#M27750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are these SAS datasets or raw data files that need to be read in?&lt;/P&gt;&lt;P&gt;Let's assume that they are data sets.&amp;nbsp; One easy way is to get the names into a dataset.&amp;nbsp; If you can use OS commands then this is easier.&lt;/P&gt;&lt;P&gt;So here is a program to look for all of the SAS datasets under the kumar folder and concatenate those with the same member name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;data&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; files ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;infile&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;'dir D:\kumar\*.sas7bdat /s/b'&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; pipe &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;truncover&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;input&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; fname &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: teal; background: white;"&gt;$256.&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;length&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ftype $&lt;/SPAN&gt;&lt;STRONG style="color: teal; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;32&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;&amp;nbsp; ftype = scan(fname,-&lt;/SPAN&gt;&lt;STRONG style="color: teal; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;2&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;'.\'&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;run&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;proc&lt;/STRONG&gt; &lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;sort&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;by&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ftype fname ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;run&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;filename&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; code &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;temp&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;data&lt;/STRONG&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;_null_&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;file&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; code ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;set&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; files;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;by&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ftype ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; first.ftype &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;then&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;put&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;'data final_'&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ftype &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;';'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;/ &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;'&amp;nbsp; set '&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;&amp;nbsp; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;put&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; fname :&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: teal; background: white;"&gt;$quote.&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; last.ftype &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;then&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;put&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;';'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;/ &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple; background: white;"&gt;'run;'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;&amp;nbsp; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: navy; background: white; font-size: 10.0pt; font-family: 'Courier New';"&gt;run&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: blue; background: white;"&gt;%inc&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black; background: white;"&gt; code / source2 ;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 05:12:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137303#M27750</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2015-01-25T05:12:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137304#M27751</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Eerily similar to this question:&lt;/P&gt;&lt;P&gt;&lt;A __default_attr="64845" __jive_macro_name="thread" class="jive_macro jive_macro_thread" href="https://communities.sas.com/"&gt;&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 06:04:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137304#M27751</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-01-25T06:04:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137305#M27752</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes thats the&amp;nbsp; question asked by friend.I have posted on his behalf.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 06:08:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137305#M27752</guid>
      <dc:creator>venkatnaveen</dc:creator>
      <dc:date>2015-01-25T06:08:23Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137306#M27753</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well he hasn't provided enough information by far to get any useful answers. We can make giant guesses and they'll probably be wrong. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For starters:&lt;/P&gt;&lt;P&gt;Are the files text files, excel files, sas datasets? &lt;/P&gt;&lt;P&gt;Do all the files have the same structure? &lt;/P&gt;&lt;P&gt;What version of SAS, can naming shortcuts be used which are in SAS 9.3+? &lt;/P&gt;&lt;P&gt;Does he mean merge i.e. add variables side by side or actually append, stack the data on top of each other?&lt;/P&gt;&lt;P&gt;What OS and does he have access to pipe commands to create a directory listing from SAS?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, he should try something as well, this is a FAQ and there are many solutions on here. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://stackoverflow.com/help/how-to-ask" title="http://stackoverflow.com/help/how-to-ask"&gt;How do I ask a good question? - Help Center - Stack Overflow&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A __default_attr="2263" __jive_macro_name="document" class="jive_macro jive_macro_document" href="https://communities.sas.com/"&gt;&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 06:31:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137306#M27753</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-01-25T06:31:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137307#M27754</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;if this question is academic, I would suggest asking the tutor.&lt;/P&gt;&lt;P&gt;If it is professional/commercial, the client/employer needs better advice than expecting an employee who does not have the skills, to provide the answer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 10:52:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137307#M27754</guid>
      <dc:creator>Peter_C</dc:creator>
      <dc:date>2015-01-25T10:52:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137308#M27755</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;since the path in the question&amp;nbsp; contains a drive reference like &lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt; D:\kumar folder.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;use dos box to create a file list with dos command like:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;dir /b/s &lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt; D:\kumar_folder &amp;gt; c:\temp\kumar_filelist.txt&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Then SAS can use that list to read all those files, or just to read the filelist&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;If the former, have a look at the FILEVAR option of the INFILE statement in the online doc and examples.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Peter Crawford : needed to fix typo and the sense......&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 10:58:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137308#M27755</guid>
      <dc:creator>Peter_C</dc:creator>
      <dc:date>2015-01-25T10:58:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137309#M27756</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Acutally&amp;nbsp; i was posted this question.&lt;/P&gt;&lt;P&gt;I am giving some more additional information&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;The files all&amp;nbsp; are having datasets.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;the datasets having the same structure i.e. same variables ex p_id, p_name, p_amt(policy id, policy holder name, policy amount)&lt;/P&gt;&lt;P&gt;i am using sas 9.2 version. windows 7 operating system&lt;/P&gt;&lt;P&gt;we have to merge all this datasets by using datastep merge but the final output only 3 three datasets that are having all&amp;nbsp; years information&lt;/P&gt;&lt;P&gt;and last the final dataset is only one i.e. final_data it contains all 10years of information&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: ravikumar kummari&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 16:50:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137309#M27756</guid>
      <dc:creator>Ravikumarkummari</dc:creator>
      <dc:date>2015-01-25T16:50:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137310#M27757</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you provide the code for how you would do this 'manually' i.e. without macros?&lt;/P&gt;&lt;P&gt;Then perhaps someone can suggest more efficient or a macro solution. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 25 Jan 2015 17:00:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137310#M27757</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-01-25T17:00:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137311#M27758</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can some one help me through this code plsss&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Jan 2015 06:32:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137311#M27758</guid>
      <dc:creator>Ravikumarkummari</dc:creator>
      <dc:date>2015-01-27T06:32:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137312#M27759</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks sir for such a great code its working i am thankful to you&lt;/P&gt;&lt;P&gt;But i am not able to understand some part of it. If you don't mind can you explain this step&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;STRONG style="font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: navy; background-position: initial;"&gt;data&lt;/STRONG&gt; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;_null_&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&amp;nbsp; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;file&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; code ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&amp;nbsp; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;set&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; files;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&amp;nbsp; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;by&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; ftype ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&amp;nbsp; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; first.ftype &lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;then&lt;/SPAN&gt; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;put&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&amp;nbsp; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;'data final_'&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; ftype &lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;';'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;/ &lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;'&amp;nbsp; set '&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;&amp;nbsp; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&amp;nbsp; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;put&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; fname :&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: teal; background-position: initial;"&gt;$quote.&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&amp;nbsp; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt; last.ftype &lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;then&lt;/SPAN&gt; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: blue; background-position: initial;"&gt;put&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&amp;nbsp; &lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;';'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;/ &lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: purple; background-position: initial;"&gt;'run;'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;&amp;nbsp; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;STRONG style="font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: navy; background-position: initial;"&gt;run&lt;/STRONG&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: 'Courier New'; color: black; background-position: initial;"&gt;I think there is a depth logic in this. Now i am a learner it is difficult for me to understand. please sir explain &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Jan 2015 10:13:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137312#M27759</guid>
      <dc:creator>Ravikumarkummari</dc:creator>
      <dc:date>2015-01-27T10:13:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137313#M27760</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;1) Start a data step that will not create any output datasets .&lt;/P&gt;&lt;P&gt;2) Direct PUT statement output to a file.&lt;/P&gt;&lt;P&gt;3 and 4) Read in the list of files in the order of FTYPE variable ;&lt;/P&gt;&lt;P&gt;5) When you read the first observation for a group of records with the same FTYPE value then write out a DATA statement and the beginning of a SET statement.&amp;nbsp; Use the value of FTYPE as part of the data set name in the DATA statement.&lt;/P&gt;&lt;P&gt;6) Write the name of the SAS dataset in quotes. The : modifier will make the quotes not include the trailing blanks in the vlaue fo FNAME. You can use this method to reference a SAS dataset directly instead of the traditional LIBNAME.MEMNAME format.&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;7) When you get to the last observation in a group then write the semicolon to end the SET statement and a RUN statement to end the data step.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;span class="lia-unicode-emoji" title=":smiling_face_with_sunglasses:"&gt;😎&lt;/span&gt; End the DATA _NULL_ step.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Jan 2015 13:06:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137313#M27760</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2015-01-27T13:06:43Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137314#M27761</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Reeza sir i tried this task and below the code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In D drive policy_folder the data is available. There will be 5 years in that. 2003 to 2007. In that subfolders are there month wise&lt;/P&gt;&lt;P&gt;I taken months names from 1 to 6. and the datasets are in the form of ds_1 to ds_4. and resultant dataset will be only one i.e. the merging all the datasets in all the years,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%macro years;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%do i=2003 %to 2007 ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%do k=1 %to 6 %by 1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;libname W_&amp;amp;k.&amp;amp;i. "E:\policy_data\&amp;amp;i.\&amp;amp;k.";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%do j=1 %to 4 %by 1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Proc append base=final data=W_&amp;amp;k.&amp;amp;i..ds_&amp;amp;j. force;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%end;&lt;/P&gt;&lt;P&gt;%end;&lt;/P&gt;&lt;P&gt;%end;&lt;/P&gt;&lt;P&gt;%mend years;&lt;/P&gt;&lt;P&gt;%years;&lt;/P&gt;&lt;P&gt;The final dataset will be stored in work library with all merging records.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Jan 2015 12:52:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137314#M27761</guid>
      <dc:creator>Ravikumarkummari</dc:creator>
      <dc:date>2015-01-28T12:52:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137315#M27762</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So what's your question now? It looks like the solution to your problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Jan 2015 16:28:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137315#M27762</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-01-28T16:28:50Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137316#M27763</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No question initially i tried this task but i didn't get proper output. So that i posted in community.&lt;/P&gt;&lt;P&gt;Later again i worked on it. Then i got output by using this code. You said you are not trying and doing your work with others. So i am posted what i have done to get the final result. That's all.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Jan 2015 16:37:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137316#M27763</guid>
      <dc:creator>Ravikumarkummari</dc:creator>
      <dc:date>2015-01-28T16:37:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to automate?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137317#M27764</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can mark you question as answered then, with your answer as the correct answer. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 28 Jan 2015 16:40:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-automate/m-p/137317#M27764</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-01-28T16:40:13Z</dc:date>
    </item>
  </channel>
</rss>

