BookmarkSubscribeRSS Feed
Question
Fluorite | Level 6

Hi All,

Basically I am merging  two tables and  I get this error…The table PADOWNER.EXPERIAN_FSS_SEGMENT looks fine, I have managed to access it.

Many Thanks

15         GOPTIONS ACCESSIBLE;

16         DATA FG_PROFILING_FINAL2;

17           MERGE NDW_FASHION_GALERY_TRANS (IN=A)

18                 PADOWNER.EXPERIAN_FSS_SEGMENT (IN=B);

ERROR: The value 'EXPERIAN_FSS_SEGMENT 'n is not a valid SAS name.

19           BY LOYALTY_ID;

20           IF A;

21         RUN;

5 REPLIES 5
arnouxvr
Fluorite | Level 6

Hi the library PADOWNER where is it connecting to?

  1. Folder with data sets
  2. Excel worksheet

You will see in the error message it is putting the dataset between ' ' followed by a n example 'EXPERIAN_FSS_SEGMENT 'n.

This is done when your dataset name does not confirm to standard dataset naming namely 32 chars must start with letter or underscore and after that any letter number or underscore.

Just try the following:

replace MERGE NDW_FASHION_GALERY_TRANS (IN=A) PADOWNER.EXPERIAN_FSS_SEGMENT (IN=B);

with MERGE NDW_FASHION_GALERY_TRANS (IN=A) PADOWNER.'EXPERIAN_FSS_SEGMENT 'n

(IN=B);

notice the ' ' and the n.

Would be good to know what you are accessing with the library.

Tushar
Obsidian | Level 7

Hi Question,

The dataset you are using in that datasets variables name, somewhere you may have mentioned single quotation (' ) . Please check your variable name once. hope that will give you some idea.

Regards,

Tushar J.

Message was edited by: Tushar Jagtap

Scott_Mitchell
Quartz | Level 8

Hi Question;

It isn't immediately apparent to me what is causing your your problem here.  If you are listing the names as above then they meet the criteria as a valid SAS name, the only thing I can think of is the encoding method.

Run the following and then view the value after ENCODING= .contained in the log.

proc options option=encoding;

run;

The maximum number of bytes allowable as a name in SAS is 32 bytes.  The SAS encodings for Western languages use one byte per character.  For Asian languages the encodings can be 1 or 2 bytes per character.  Whilst UTF-8 can be between 1 and 4 bytes per character.

Check this out and if this isn't the problem let me know and I will investigate further.

Regards,

Scott

jakarman
Barite | Level 11

Hi Question,

Te message is strange. All code looks well but after the Segment an invisable or blank is taken into the name.

ERROR: The value 'EXPERIAN_FSS_SEGMENT 'n is not a valid SAS name.

Having copied (cut/paste) code form eg Word sometimes weird character are included (UTF), see Scott.

removing that and retyping making sure normal chars are in your code and not a lost binary-zero or something like that.     

---->-- ja karman --<-----
surveystudent
Calcite | Level 5

Hi all I am using SAS to do a conjoint analysis for my master thesis.I am trying to get the output of choice sets but not getting anything.This is the code.I would much appreciate your help.

%mktruns(32 23)

%mktex
(
3 22 3),n=36,seed=100

%macro
restrict;
bad=(x1=1& x4=1) + (x1=3& x4=3)

%mend;

%mktex(3 22 3),n=36
, seed=
100,restrictions=restrict) ;

Procprint data=design;

%mktlab
(
data=design , int=f1-f3 )

%choiceff
(
data=final,model=class (x1-x5) , nsets=18
, flag=f1-f3 , beta=
2 1 21 21 21 21,seed=100, maxiter=20)

Proc print ; id set ; by
set ;
run

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!

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.

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
  • 5 replies
  • 999 views
  • 0 likes
  • 6 in conversation