<?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 Importing XLSX to WORK in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595662#M15836</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to import an XLSX file. I'm currently doing it like this:&lt;/P&gt;
&lt;P&gt;libname MYLIB XLSX "my_file.xlsx" access=readonly;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The problem with this is that I need to rename the variables and send them to the WORk lib.&lt;/P&gt;
&lt;P&gt;Is there a way I could import directly to WORK?&lt;/P&gt;
&lt;P&gt;I tried chaging the libname parameter but it didn't work...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards&lt;/P&gt;</description>
    <pubDate>Fri, 11 Oct 2019 08:08:59 GMT</pubDate>
    <dc:creator>polpel</dc:creator>
    <dc:date>2019-10-11T08:08:59Z</dc:date>
    <item>
      <title>Importing XLSX to WORK</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595662#M15836</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to import an XLSX file. I'm currently doing it like this:&lt;/P&gt;
&lt;P&gt;libname MYLIB XLSX "my_file.xlsx" access=readonly;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The problem with this is that I need to rename the variables and send them to the WORk lib.&lt;/P&gt;
&lt;P&gt;Is there a way I could import directly to WORK?&lt;/P&gt;
&lt;P&gt;I tried chaging the libname parameter but it didn't work...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2019 08:08:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595662#M15836</guid>
      <dc:creator>polpel</dc:creator>
      <dc:date>2019-10-11T08:08:59Z</dc:date>
    </item>
    <item>
      <title>Re: Importing XLSX to WORK</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595664#M15837</link>
      <description>&lt;P&gt;Note that there are two sheets in my excel file&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2019 08:11:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595664#M15837</guid>
      <dc:creator>polpel</dc:creator>
      <dc:date>2019-10-11T08:11:11Z</dc:date>
    </item>
    <item>
      <title>Re: Importing XLSX to WORK</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595670#M15839</link>
      <description>&lt;P&gt;You could switch to proc import, but you need one for each sheet, so keeping libname-statement seems to be easier. You can copy datasets using proc copy:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc copy in=mylib out=work;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;This step copies all sheets/datasets from mylib to work.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For renaming variable proc datasets with modify seem to be the best tool.&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2019 08:54:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595670#M15839</guid>
      <dc:creator>andreas_lds</dc:creator>
      <dc:date>2019-10-11T08:54:42Z</dc:date>
    </item>
    <item>
      <title>Re: Importing XLSX to WORK</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595678#M15841</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/291423"&gt;@polpel&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As you anyway have to copy the data just use a data step where you can also rename the variables and do whatever other transformations you need.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Using a SAS data step makes it also really simple to combine the two source sheets into a single table in Work.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Oct 2019 10:58:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Importing-XLSX-to-WORK/m-p/595678#M15841</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2019-10-11T10:58:17Z</dc:date>
    </item>
  </channel>
</rss>

