Hello Experts,
In my xlsx file I have this kind of data :
When I do the proc import, I have this result :
Do you know please, how to import the xlsx file in correcte way please to have the correct appearance of amount with % ?
Thank you !
Save from Excel as csv, inspect the file with a text editor, and read it with a data step.
The text in the first row forces the variable to be character, and the numbers are taken as raw values; since you also seem to have a numeric precision artifact in Excel, you get the funny representation.
Best remedy for such mixed data: save the file as csv, and read it with a data step where you can deal with "special" values.
What would you expect to get from the first row?
Save from Excel as csv, inspect the file with a text editor, and read it with a data step.
Are you allowed to edit the Excel file?
If so, try creating an extra column, and add any "explanatory text" (such as "avec un mini de 50...") to that extra column. Once the numeric data column has only numeric data in it, it should be much easier for SAS to import.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.