Hi,
Just experimenting with very basic raw data reading and I'm getting stumped with this error.
Any insight or help will be appreciated
The error shows the program I am running .. the raw data is 24/12/1856765
The first 8 characters is the date 24/12/18 i am trying to read with the informat ddmmyy8. but its throwing an error
By using the colon modifier you told SAS to read all of the characters up to the next delimiter (or end of line) using the MMDDYY informat.
Note that in list mode the INPUT statement ignores the width on the informat and uses the width of the actual next word of data. SAS cannot make a date value with a year of 1,856,765.
Just remove the : from the INPUT statement.
Can you paste the datalines as well plz?
I can't see the data
data test;
input date ddmmyy8. amount;
format date date9. amount dollar16.2;
cards;
24/12/1856765
;
By using the colon modifier you told SAS to read all of the characters up to the next delimiter (or end of line) using the MMDDYY informat.
Note that in list mode the INPUT statement ignores the width on the informat and uses the width of the actual next word of data. SAS cannot make a date value with a year of 1,856,765.
Just remove the : from the INPUT statement.
Thanks guys ... silly silly mistake ..
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
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.
Select SAS Training centers are offering in-person courses. View upcoming courses for: