Hi,
I've been having a hard time with my new computer system that's why I have all the posts.
Anyway, I'm importing a .dbf using the import wizard and some of my date variables are being changed from datetime to character. This confuses sas when I run datasteps for coding.
I attempted to change the format in the datastep for example;
DATA WORK.ANALYSIS;
ATTRIB CLOSED_DT FORMAT=MMDDYY8.;
SET WORK.ANALII;
CODE;
CODE;
CODE;
CODE;
RUN;
When I run this I get the error:
ERROR: Variable CLOSED_DT has been defined as both character and numeric.
When I look at the original .xls I have it formated as a date. Then I have to save it as a .dbf (don't ask why it's a long story) where I'm assuming it is understood that it's a number, but when I look at the contents of the SAS file after import but before the coding datastep it reads as a character.
Any thoughts?
Thanks in advance.
I've been having a hard time with my new computer system that's why I have all the posts.
Anyway, I'm importing a .dbf using the import wizard and some of my date variables are being changed from datetime to character. This confuses sas when I run datasteps for coding.
I attempted to change the format in the datastep for example;
DATA WORK.ANALYSIS;
ATTRIB CLOSED_DT FORMAT=MMDDYY8.;
SET WORK.ANALII;
CODE;
CODE;
CODE;
CODE;
RUN;
When I run this I get the error:
ERROR: Variable CLOSED_DT has been defined as both character and numeric.
When I look at the original .xls I have it formated as a date. Then I have to save it as a .dbf (don't ask why it's a long story) where I'm assuming it is understood that it's a number, but when I look at the contents of the SAS file after import but before the coding datastep it reads as a character.
Any thoughts?
Thanks in advance.