- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Posted 08-16-2010 07:20 AM
(1879 views)
Hi,
I wanted to use PROC COPY for copying a dataset but received an error after submitting the following:
proc copy out=work in=ntsqlpro;
select LÅN_GARANTI;
quit;
ERROR: The value 'LÅN_GARANTI'n is not a valid SAS name.
I am running 9.1.3. I assume that it is because of the special character in the original dataset name. Is there a way to circumvent this or is it not possible to use PROC COPY with special characters? I googled the web for explanations but didn't come across any.
Thanks,
Helle
I wanted to use PROC COPY for copying a dataset but received an error after submitting the following:
proc copy out=work in=ntsqlpro;
select LÅN_GARANTI;
quit;
ERROR: The value 'LÅN_GARANTI'n is not a valid SAS name.
I am running 9.1.3. I assume that it is because of the special character in the original dataset name. Is there a way to circumvent this or is it not possible to use PROC COPY with special characters? I googled the web for explanations but didn't come across any.
Thanks,
Helle
4 REPLIES 4
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Works fine for me. My guess is that you have the wrong value set for your validvarname option.
Try options validvarname=v7 and see if that corrects the problem.
HTH,
Art
Try options validvarname=v7 and see if that corrects the problem.
HTH,
Art
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
It is hard to tell, but it looks like the A in LAN is not the standard English A. This would require VALIDVARNAME to be set to ANY. You may also need to write the SELECT statement as:
[pre]
select 'LAN_GARANTI'n;
[/pre]
where you use the A that is not on my keyboard.
[pre]
select 'LAN_GARANTI'n;
[/pre]
where you use the A that is not on my keyboard.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Helle
you need to change the name of the table if you want to copy it into the WORK library. Although SAS/Access to a dbms supports complex names like your table, that flexibility is not present in the support of table names in the (base SAS) WORK library.
You might have more success with a simple data step, like[pre]DATA work.loan_garanti ;
set ntsqlpro."LÅN_GARANTI"n ;
run ;[/pre]
good luck
peterC
you need to change the name of the table if you want to copy it into the WORK library. Although SAS/Access to a dbms supports complex names like your table, that flexibility is not present in the support of table names in the (base SAS) WORK library.
You might have more success with a simple data step, like[pre]DATA work.loan_garanti ;
set ntsqlpro."LÅN_GARANTI"n ;
run ;[/pre]
good luck
peterC
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
In the end, I opted for the simple data step solution because I still received the same error message even after changing the options and modifying the code. Thanks for all your input.
Helle
In the end, I opted for the simple data step solution because I still received the same error message even after changing the options and modifying the code. Thanks for all your input.
Helle