Collections:
CURDATE() - Current Date
How to obtain the current date using the CURDATE() function?
✍: FYIcenter.com
CURDATE() is a MySQL built-in function that
returns the current date.
For example:
SELECT CURDATE(), CURDATE()+1; -- +------------+-------------+ -- | CURDATE() | CURDATE()+1 | -- +------------+-------------+ -- | 2023-11-11 | 20231112 | -- +------------+-------------+
Reference information of the CURDATE() function:
CURDATE(): dt Returns the current date as a value in 'YYYY-MM-DD' or YYYYMMDD format, depending on whether the function is used in string or numeric context. Arguments, return value and availability: dt: Return value. The current date as a string or number. Available since MySQL 4.
Related MySQL functions:
⇒ CURRENT_DATE() - Synonym for CURDATE()
⇐ CONVERT_TZ() - Converting Time Zone
2023-11-17, 903🔥, 0💬
Popular Posts:
How To List All Login Names on the Server in SQL Server? If you want to see a list of all login name...
What are binary literals supported in SQL Server Transact-SQL? Binary literals in Transact-SQL are s...
How to download and install Microsoft .NET Framework Version 2.0 in SQL Server? .NET Framework Versi...
How To Drop a Stored Procedure in Oracle? If there is an existing stored procedure and you don't wan...
Where to find tutorials to answer some frequently asked questions on Microsoft SQL Server Transact-S...