<?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: Data sets into Single .Csv With Multiple Sheets in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587751#M167890</link>
    <description>&lt;P&gt;If my assumption is correct, you can do something like this and insert the relevant path. Then import the CSV Files to Excel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data a;set sashelp.class;run;
data b;set sashelp.class;run;
data c;set sashelp.class;run;

data _null_;
    set sashelp.vtable(where=(libname='WORK') keep=libname memname);
    call execute(compbl(cat(

    "Proc export data=",memname, "
        outfile='INSERT_PATH_HERE\", memname, ".csv'
        dbms=csv
        replace;
    run;"

    )));
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Wed, 11 Sep 2019 08:04:42 GMT</pubDate>
    <dc:creator>PeterClemmensen</dc:creator>
    <dc:date>2019-09-11T08:04:42Z</dc:date>
    <item>
      <title>Data sets into Single .Csv With Multiple Sheets</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587733#M167884</link>
      <description>&lt;P&gt;Dear All&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have multiple(More than 10)date sets in Work Library and i want them into Single .CSV file With Multiple Sheets(each data set in different sheets on a Single .Csv File).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can Anyone Help Me with Proper Code For above problem.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you in Advance&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&amp;nbsp;&lt;/P&gt;&lt;P&gt;Nehemiah&lt;/P&gt;</description>
      <pubDate>Wed, 11 Sep 2019 06:56:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587733#M167884</guid>
      <dc:creator>Nehemiah</dc:creator>
      <dc:date>2019-09-11T06:56:35Z</dc:date>
    </item>
    <item>
      <title>Re: Data sets into Single .Csv With Multiple Sheets</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587735#M167885</link>
      <description>&lt;P&gt;&lt;SPAN&gt;CSV files are plain text files. Not spreadsheet files. Therefore, you can not have multiple sheets in a single CSV file. It does not make sense.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I assume that what you actually want is to export data into multiple sheets in an .XLSX file?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Sep 2019 06:59:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587735#M167885</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2019-09-11T06:59:37Z</dc:date>
    </item>
    <item>
      <title>Re: Data sets into Single .Csv With Multiple Sheets</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587741#M167886</link>
      <description>&lt;P&gt;sir&amp;nbsp;thanks for your solution.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;sir l will explain in a clear manner.i have an excel file with some data..and my SAS Environment have permissions only for CSV files to import and export.so when i want to get the from excel to sas data set firstly i convert that excel into .csv and that file looked as excel..&lt;/P&gt;&lt;P&gt;so that's why i am asking multiple data sets into csv.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thank you&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;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Sep 2019 07:22:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587741#M167886</guid>
      <dc:creator>Nehemiah</dc:creator>
      <dc:date>2019-09-11T07:22:09Z</dc:date>
    </item>
    <item>
      <title>Re: Data sets into Single .Csv With Multiple Sheets</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587748#M167888</link>
      <description>&lt;P&gt;This could be done with multiple data-null-steps using file-statement and the mod option. But i would not export datasets with different variables into one file.&lt;/P&gt;</description>
      <pubDate>Wed, 11 Sep 2019 07:47:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587748#M167888</guid>
      <dc:creator>andreas_lds</dc:creator>
      <dc:date>2019-09-11T07:47:39Z</dc:date>
    </item>
    <item>
      <title>Re: Data sets into Single .Csv With Multiple Sheets</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587749#M167889</link>
      <description>&lt;P&gt;I Don't follow this exactly. Do you want to export all the data sets into a single .CSV file? I would not recommend that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think what you want to do is to export the data sets into multiple .CSV files and then import those into a single Excel Workbook with multiple sheets (1 for each .CSV File)).&lt;/P&gt;</description>
      <pubDate>Wed, 11 Sep 2019 07:53:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587749#M167889</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2019-09-11T07:53:06Z</dc:date>
    </item>
    <item>
      <title>Re: Data sets into Single .Csv With Multiple Sheets</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587751#M167890</link>
      <description>&lt;P&gt;If my assumption is correct, you can do something like this and insert the relevant path. Then import the CSV Files to Excel&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data a;set sashelp.class;run;
data b;set sashelp.class;run;
data c;set sashelp.class;run;

data _null_;
    set sashelp.vtable(where=(libname='WORK') keep=libname memname);
    call execute(compbl(cat(

    "Proc export data=",memname, "
        outfile='INSERT_PATH_HERE\", memname, ".csv'
        dbms=csv
        replace;
    run;"

    )));
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 11 Sep 2019 08:04:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Data-sets-into-Single-Csv-With-Multiple-Sheets/m-p/587751#M167890</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2019-09-11T08:04:42Z</dc:date>
    </item>
  </channel>
</rss>

