CURDATE() : CURDATE : Date Time Functions MySQL TUTORIALS


MySQL TUTORIALS » Date Time Functions » CURDATE »

 

CURDATE()


Returns the current date as a value in 'YYYY-MM-DD' or YYYYMMDD format, depending on whether the function is used in a string or numeric context.

CURRENT_DATE is the synonym for CURDATE().

mysql>
mysql> SELECT CURDATE();
+------------+
| CURDATE()  |
+------------+
2007-07-22 |
+------------+
row in set (0.00 sec)

mysql> SELECT CURDATE() 0;
+---------------+
| CURDATE() |
+---------------+
|      20070722 |
+---------------+
row in set (0.00 sec)

mysql>
mysql>
mysql> select CURRENT_DATE();
+----------------+
| CURRENT_DATE() |
+----------------+
2007-07-22     |
+----------------+
row in set (0.00 sec)

mysql>
mysql>
mysql>



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .

Follow Navioo On Twitter

MySQL TUTORIALS

 Navioo Date Time Functions
» CURDATE