Thread: date formation problems

date formation problems

From
"Ray Messier"
Date:

i have a table  ....

create table foo ( dfield datetime );

when i do an insert the date always comes out as 1969! any ideas why?

$cSQL = "INSERT INTO foo (dfield) VALUES ('" . date("m/d/Y h:m
a","12/09/2001 02:15 am") . "')";
pg_exec($oConn, $cSQL);

Attachment