<?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: proc import in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59413#M16764</link>
    <description>Thanks  &lt;BR /&gt;
&lt;BR /&gt;
I had one more question ... &lt;BR /&gt;
&lt;BR /&gt;
The variable names I get after import are all having special characters like  " : % ( ) , # .. however, I want the imported columns to follow the SAS variable naming convention is there any option for that ??

Message was edited by: rickw</description>
    <pubDate>Thu, 06 Jan 2011 18:21:21 GMT</pubDate>
    <dc:creator>rickw</dc:creator>
    <dc:date>2011-01-06T18:21:21Z</dc:date>
    <item>
      <title>proc import</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59411#M16762</link>
      <description>Hi,&lt;BR /&gt;
&lt;BR /&gt;
I am currently using SAS EG 4.2 and I get weird error on trying to run simple proc import :&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
proc import out = temp datafile = "C:\Users\Downloads\Temp.xls"&lt;BR /&gt;
dbms = xls replace ;&lt;BR /&gt;
sheet = combined;&lt;BR /&gt;
run;&lt;BR /&gt;
&lt;BR /&gt;
ERROR: Physical file does not exist&lt;BR /&gt;
&lt;BR /&gt;
Would be great if you guys could help me with this. &lt;BR /&gt;
&lt;BR /&gt;
Also, is there any way I could import all the tabs in my excel files into sas tables with name corresponding to each tab name ?? &lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Thanks.</description>
      <pubDate>Wed, 05 Jan 2011 23:32:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59411#M16762</guid>
      <dc:creator>rickw</dc:creator>
      <dc:date>2011-01-05T23:32:36Z</dc:date>
    </item>
    <item>
      <title>Re: proc import</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59412#M16763</link>
      <description>Hi.&lt;BR /&gt;
The log displays ERROR: Physical file does not exist. maybe temp.xls is not the right path.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&amp;gt;Also, is there any way I could import all the tabs in my excel files into sas tables with name corresponding to each tab name ??&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Sure.you need "libname x excel 'xxxx' " statement to assign a libname to excel file ,then use 'proc sql ......from dictionary.tables' to yield the sheet name in that xls file.then use %do macro .&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Ksharp</description>
      <pubDate>Thu, 06 Jan 2011 03:33:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59412#M16763</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2011-01-06T03:33:49Z</dc:date>
    </item>
    <item>
      <title>Re: proc import</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59413#M16764</link>
      <description>Thanks  &lt;BR /&gt;
&lt;BR /&gt;
I had one more question ... &lt;BR /&gt;
&lt;BR /&gt;
The variable names I get after import are all having special characters like  " : % ( ) , # .. however, I want the imported columns to follow the SAS variable naming convention is there any option for that ??

Message was edited by: rickw</description>
      <pubDate>Thu, 06 Jan 2011 18:21:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59413#M16764</guid>
      <dc:creator>rickw</dc:creator>
      <dc:date>2011-01-06T18:21:21Z</dc:date>
    </item>
    <item>
      <title>Re: proc import</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59414#M16765</link>
      <description>Yes.&lt;BR /&gt;
There is a system option ' options validvarname=any ' can use any special character for variable name (only available for Base and Stat).&lt;BR /&gt;
If you do not want, can close it or change it.&lt;BR /&gt;
&lt;BR /&gt;
Ksharp</description>
      <pubDate>Fri, 07 Jan 2011 03:30:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59414#M16765</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2011-01-07T03:30:29Z</dc:date>
    </item>
    <item>
      <title>Re: proc import</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59415#M16766</link>
      <description>I actually meant that I want to follow the SAS naming rules that is having underscore instead of special characters ...&lt;BR /&gt;
&lt;BR /&gt;
When I import the data it is not getting converted to variable naming convention this is just happening for excel files... &lt;BR /&gt;
&lt;BR /&gt;
when I import csv files the variable names are following the SAS naming convention... &lt;BR /&gt;
&lt;BR /&gt;
I tried options validvarname = v7..&lt;BR /&gt;
&lt;BR /&gt;
but that gives some error .. &lt;BR /&gt;
&lt;BR /&gt;
ERROR: The value Assigned To: Full Name is not a valid SAS name.&lt;BR /&gt;
&lt;BR /&gt;
Thanks.</description>
      <pubDate>Fri, 07 Jan 2011 17:18:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59415#M16766</guid>
      <dc:creator>rickw</dc:creator>
      <dc:date>2011-01-07T17:18:18Z</dc:date>
    </item>
    <item>
      <title>Re: proc import</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59416#M16767</link>
      <description>Hi.&lt;BR /&gt;
I try it.&lt;BR /&gt;
In fact, SAS will use your illegal variable name as label.And variable is actually converted successful.&lt;BR /&gt;
&lt;BR /&gt;
If you add another options '  options nolabel ; ' then you will find SAS has already convert varname as the rule of V7.&lt;BR /&gt;
&lt;BR /&gt;
Or use proc contents to see it deeply.&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Ksharp</description>
      <pubDate>Mon, 10 Jan 2011 01:59:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/proc-import/m-p/59416#M16767</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2011-01-10T01:59:39Z</dc:date>
    </item>
  </channel>
</rss>

