BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
BillB
Fluorite | Level 6

We have upgraded a short time ago from EG 6.1 to 7.1.

I just tried, as I have previoulsy done successfully, importing an Excel file (previoulsy tested) and I learned that if I import it the first time it will generate a data set.

If I close out the app of project and try a second time it will not generate a data set. It will only show a Log and code windows with a Log summary without any errors only notes.

1 ACCEPTED SOLUTION

Accepted Solutions
CaseySmith
SAS Employee

Hi Bill,

I am able to reproduce the problem in EG 7.1.  It only occurs if the output data set name contains extended characters and it already exists.  From your log (and my repro steps), the output data set is not being properly quoted the second time.  For example, the generated code looks like...

DATA WORK.NCRF MEMBERSHIP FILE TYPE L_0000;

...which is invalid code, since the member name contains extended characters (spaces), but is not quoted.  Valid code (properly quoted member name) would look like...

DATA WORK.'NCRF MEMBERSHIP FILE TYPE L_0000'n;

I can think of a few ways to workaround...

1. Explicitly change the output data set name on the first page of the Import Wizard, so that it doesn't contain extended characters (ex. replace the spaces with underscores),

2. Delete the already existing imported/output table before importing it the second time.

3. Rename the .xls file so that it doesn't contain extended characters (remove the spaces).

I'll work with tech support to make sure this is tracked and fixed.

Casey


Register today and join us virtually on June 16!
sasglobalforum.com | #SASGF

View now: on-demand content for SAS users

View solution in original post

7 REPLIES 7
Steelers_In_DC
Barite | Level 11

I'm not sure without seeing the log but it sounds like you are importing something that is already in your work library.  If this is the case it will not generate a dataset but you have access to it in your work library.  Either expand your libraries  and go to your work folder, there you can double click, or you can write the code that will generate it. I would only do this if it is a small dataset.

data test;

set 'name here';

run;

BillB
Fluorite | Level 6

Mark;

Thanks for the reply.

I was able to do this procedure in e.g. 6.1 without a proble.

I've reached out to SAS Tech Support who have a copy of the Log & Code which I also thought that I attached to this original discussion.

The data set is very small.

Steelers_In_DC
Barite | Level 11

Can you view the dataset using either of the two options I suggested?

CaseySmith
SAS Employee

Hi Bill,

I am able to reproduce the problem in EG 7.1.  It only occurs if the output data set name contains extended characters and it already exists.  From your log (and my repro steps), the output data set is not being properly quoted the second time.  For example, the generated code looks like...

DATA WORK.NCRF MEMBERSHIP FILE TYPE L_0000;

...which is invalid code, since the member name contains extended characters (spaces), but is not quoted.  Valid code (properly quoted member name) would look like...

DATA WORK.'NCRF MEMBERSHIP FILE TYPE L_0000'n;

I can think of a few ways to workaround...

1. Explicitly change the output data set name on the first page of the Import Wizard, so that it doesn't contain extended characters (ex. replace the spaces with underscores),

2. Delete the already existing imported/output table before importing it the second time.

3. Rename the .xls file so that it doesn't contain extended characters (remove the spaces).

I'll work with tech support to make sure this is tracked and fixed.

Casey


Register today and join us virtually on June 16!
sasglobalforum.com | #SASGF

View now: on-demand content for SAS users

Kurt_Bremser
Super User

Make your life easier and adhere to the validvarname=v7 principles.

Especially follow the "no blanks in filenames / pathnames" rule. Blanks in names are just a major PITA easily avoided.

Peter_L
Quartz | Level 8

Blanks in filenames may be replaced with underscores. These cause other problems, e.g. if the files are on SharePoint system the names will not be wrapped at the underscore, which can create unreadable displays of long file names. Modern software should be able to deal with any valid filenames, including spaces and accented characters, without jumping through hoops. Internationalisation requires this. This appears to be a regression bug in SAS.

BillB
Fluorite | Level 6

Thanks Peter!

That's is exactly the case in tis situation.

Lessons learned!

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 7 replies
  • 1743 views
  • 7 likes
  • 5 in conversation