BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Aexor
Lapis Lazuli | Level 10

How to read value like this 

 

03/2020 - sunday check 3x75g

 

This value is present in csv file along with many other variables values. This particular column (values like 03/2020 - sunday check 3x75g)  which is  as mentioned is coming as blank . Please advise

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User
You will need to read it in as a single character variable initially and then parse out the components if you'd like.

If you read the file using PROC IMPORT try setting GUESSINGROWS=MAX to force SAS to scan the entire file before it assigns types and that may fix part of the issue for you.
If you're reading in using INPUT/INFILE then you need to ensure the informat is set to character with an appropriate length.

View solution in original post

2 REPLIES 2
andreas_lds
Jade | Level 19

Please post a complete line of the csv file using "insert code" and show the code you have used to read the file.

Reeza
Super User
You will need to read it in as a single character variable initially and then parse out the components if you'd like.

If you read the file using PROC IMPORT try setting GUESSINGROWS=MAX to force SAS to scan the entire file before it assigns types and that may fix part of the issue for you.
If you're reading in using INPUT/INFILE then you need to ensure the informat is set to character with an appropriate length.

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

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
  • 2 replies
  • 603 views
  • 1 like
  • 3 in conversation