Page 1 of 1

now() function for inserting date....?

Posted: Wed Mar 22, 2006 4:16 am
by heerajee
Hi,
I am wasting alot of time on this, but the current date is not being inserted.
mysql_query("update courierinfo set cstatus=1,Delivereddate=".NOW()." where id='".$_REQUEST['trid']."'");



Plz tell me where is the error.
Thanks in advance.

Posted: Wed Mar 22, 2006 4:36 am
by s.dot
I believe NOW is an SQL function and not php

try it without concatenating

set delivereddate=NOW()

Posted: Wed Mar 22, 2006 5:04 am
by AndyFielder
scrotaye wrote:I believe NOW is an SQL function and not php

try it without concatenating

set delivereddate=NOW()
Yup, thats how to do it!