On Thursday 05 February 2004 15:45, Brian Dunning wrote: > Sorry this is such a basic question - but I couldn't find it online. > > I have a date field in MySQL: 0000-00-00. I'm trying to insert or > search for the current date, and I can't find the way to state that in > the SQL. This is wrong, can someone please tell me what's correct? > > INSERT INTO mytable (dateField) VALUE (CURRENT_DATE); > > SELECT * FROM mytable WHERE dateField = CURRENT_DATE;
NOW() is the mysql function for the current date. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php