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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adding function.. (CURDATE) 1

Status
Not open for further replies.

perlone

Programmer
May 20, 2001
438
US
I want to add the curent date but how do I add this to my program?


insert into news (nid,subject,body,date)values('0','$ntitle','$nbody','CURDATE')

Code listed above isn't adding the current date. Anybody can tell me how to do this? Thanks. There is no Knowledge that is not power.
Age: 16
E-mail: projectnet01@yahoo.com
School: Coral Springs High (Company:(not done yet) :)
Status: Currently working with C++ for game developing. And making a musical band.
-Aaron
 


insert into news (nid,subject,body,date)values('0','$ntitle','$nbody','CURDATE()') <---you need the parenthesis

 
Thank you so much! There is no Knowledge that is not power.
Age: 16
E-mail: projectnet01@yahoo.com
School: Coral Springs High (Company:(not done yet) :)
Status: Currently working with C++ for game developing. And making a musical band.
-Aaron
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top