BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
SASuserlot
Barite | Level 11

Thank you @Reeza . It worked and served my purpose now.   I informed the upper level about this issue  since its from a vendor.  From this post I came to learn extend ( new option) and how to deal with these kind of Issues. Thanks to you all. special mentions to @Reeza @SASKiwi  @Kurt_Bremser @Tom  for you time on this issue

Tom
Super User Tom
Super User

You cannot use hyphen in a dataset name.

Example:

456  options validmemname=extend;
NOTE: Windowing environment support for VALIDMEMNAME=EXTEND is limited to Editor, Log, and Output windows.
457  data "test-name"n ;
458    x=1;
459  run;

ERROR: The value TEST-NAME is not a valid SAS member name.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: DATA statement used (Total process time):
      real time           0.01 seconds
      cpu time            0.00 seconds

Reprimand the fool that created the file.

Rename or copy the file to one with a valid name and then SAS will be able to use it.

SASKiwi
PROC Star

@Tom - I should have read the documentation for EXTEND a bit closer - see below.

@SASuserlot  - I believe your offending dataset is on your local PC drive. If so just go into Windows Explorer, make a copy of the dataset file, then rename it and remove the hyphen. I can only assume the producer of the file has renamed it manually like this as you can't create a dataset containing a hyphen in the name in SAS itself.

 

EXTEND

specifies that a SAS data set name, a SAS data view name, or an item store name must follow these rules:

  • Names can include national characters.
  • The name can include special characters, except for the / \ * ? " < > |: -. characters

 

sas-innovate-wordmark-2025-midnight.png

Register Today!

Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.


Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 17 replies
  • 2595 views
  • 5 likes
  • 5 in conversation