Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

The format $DATE was not found or could not be loaded

Status
Not open for further replies.

242526GEN

Programmer
Jun 9, 2003
2
US
Can anyone tell me what is wrong with this statement. I keep getting the error. The format $DATE was not found or could not be loaded. I am new to using SAS. I think should work.


(Statement)
ckdate2 = put(symget ('batparm3'), date9.);

(Error)
The format $DATE was not found or could not be loaded.
 
That is because your parameter batparm3 is not a SAS date.
Let's look the following example:

1 data tst;
2 date1 = '01jan2003'd;
3 date2 = put(date1, date9.);
4 run;

NOTE: The data set WORK.TST has 1 observations and 2 variables.
NOTE: DATA statement used:
real time 0.41 seconds
cpu time 0.00 seconds

The data looks like this:

obs date1 date2
1 15706 01JAN2003

Please note that date1 is a number! SAS date is stored as numerical field, with Jan 1 1960 as 1, and can be expressed with different format.

Let's look at what happens if you have a character field:

6 data tst;
7 date1 = '01jan2003';
NOTE: SCL source line.
8 date2 = put(date1, date9.);
------
48
ERROR 48-59: The format $DATE was not found or could not be loaded.

9 run;

That is the error you got.

Please provider you parameter along with what you like to have for ckdate2. We will be able to help you from there.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top