I agree with John, this is a REAL basic thing. Please read over the relevant portions of the manual. I'll give you a quick sample though. // selecting data based on a date $sql = "select fieldOne, fieldTwo, fieldThree, myDateField from myTable where myDate>'2002-10-09';"; $rs = mysql_query($sql); // writing to a date field $sql = "update myTable set myDateField='2002-10-09' where myTableID=5;"; $rs = mysql_query($sql); HTH, =C= * * Cal Evans * The Virtual CIO * http://www.calevans.com * -----Original Message----- From: Robert Leahong [mailto:rleahong@hotmail.com] Sent: Wednesday, October 09, 2002 10:57 AM To: php-db@lists.php.net Subject: DEALING WITH RETRIEVING AND WRITING DATE VALUE FROM/TO TABLE I need to know how to retrieve a date field from a database table using MYSQL_DB_QUERY to create recordset. As well as writing a Date Variable to a table using MYSQL_QUERY . YOURS Truly, Robert Leahong. rleahong@hotmail.com _________________________________________________________________ Chat with friends online, try MSN Messenger: http://messenger.msn.com -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php