# How can I transform a column into date format?

One of my date column doesn't read in date format, but I need to use the function WEEKDAY() on it. How can I transform the data format of that column into date format?

UPDATE: It is a csv file, following is one of the rows

01OCT2007,4.92,7.75

-
Can you tell how the column looks in the source data file? Is it a csv/txt file after all? –  psj Dec 7 '11 at 12:27
@psj This is a csv file –  Benjamin Dec 7 '11 at 12:56

data foo;
infile "foo.txt" delimiter=',';
informat a date.;
format a date.;
input a b c;
run;


?

psj

-
Thanks!! It works!! Would you mind telling me why I cant use PROC import to handle the date? –  Benjamin Dec 7 '11 at 13:34
@Benjamin: you can. If I use instead PROC IMPORT OUT= WORK.FOO DATAFILE= "foo.csv" DBMS=CSV REPLACE; GETNAMES=NO; DATAROW=1; RUN; I get the same result as above. –  psj Dec 7 '11 at 13:42
Hum.. My code should be something wrong, I cant work with this code. Anyway Thanks!! –  Benjamin Dec 7 '11 at 14:02