Dear all,
I am trying to write a code with Proc Import to import a *.txt file, in which there is a variable containing "card numbers" (field name: [T:L:100]CARD_NO) with 16 digits. However, after importing, the values showed in the variable are numeric as "4.69672E15". Please help to instructing me to:
PROC IMPORT OUT= WORK.PORTFOLIO_TODAY
DATAFILE="&rprt_cust_info.CC Customer Info &RPRT_TODAY..TXT"
DBMS=DLM REPLACE;
GETNAMES=YES;
GUESSINGROWS=10000;
DELIMITER="09"X;
RUN;
1/ Keep the format of the variable as "character" when importing instead of changing the format with "data steps" after the importing.
or
2/ Import all the variable as "character" format.
Thank you so much.
As @Reeza already explained how to solve the problem, i'd like to add one thing: switch of caps-lock when writing code. All those uppercase chars reduce readability.
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
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.
Ready to level-up your skills? Choose your own adventure.