SQL CURDATE

SQL CURDATE is a MySQL function which returns current date based on server system.

Note: MySQL has 3 similar functions:
SQL NOW() : return date and time
SQL CURDATE: returns date
SQL CURTIME: returns time

SQL CURDATE() Syntax

SELECT CURDATE()

SQL CURDATE() Example

SELECT CURDATE()

The result will look like:
2011-09-25

SELECT NOW()
          , CURDATE()
          , CURTIME()

The result will look like:

NOW() CURDATE() CURTIME()
2011-09-25 03:43:18 2011-09-25 03:43:18

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>