I bet you it's the ' around the currentdate()-function that causes it to interpret it as a string instead of a function call. And afaik there is no currentdate()-function in mysql, it's now().
At 15:02 2002-09-25 -0400, Marlene Burckhalter wrote: >I am trying to display an event calendar in an html document ( I am a >beginner, I had to start small). >My problem is the following query displays all the records instead of just >the ones with the event date greater than or equal to the current date. > >Any suggestions to a begginer? Here is a snipplet: > > $query = "SELECT eventmonth FROM $create_calendar_tablename > WHERE eventdate >= 'currentdate()' > LIMIT 19"; > $result = mysql_query($query); > if(!$result) error_message(sql_error()); > while($query_data = mysql_fetch_array($result)) { > echo $query_data["eventmonth"],"<P>"; > } -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php