Collections:
Extract Unit Values from a Date and Time in MySQL
How To Extract a Unit Value from a Date and Time in MySQL?
✍: FYIcenter.com
If you want to extract a specific date or time unit value out of a date or a time, you can use the EXTRACT(unit FROM expression) function. The tutorial exercise below gives you some good examples:
ELECT EXTRACT(DAY FROM NOW()) FROM DUAL; 28 ELECT EXTRACT(HOUR FROM NOW()) FROM DUAL; 23 ELECT EXTRACT(SECOND FROM NOW()) FROM DUAL; 36
⇒ Date and Time Functions in MySQL
⇐ Presenting a Past Time in Hours, Minutes and Seconds in MySQL
2018-03-13, 3201🔥, 0💬
Popular Posts:
Is SQL Server Transact-SQL case sensitive? No. Transact-SQL is not case sensitive. Like the standard...
What Is Program Global Area (PGA) in Oracle? A Program Global Area (PGA) is a memory buffer that is ...
What Are Bitwise Operations in SQL Server Transact-SQL? Bitwise operations are binary operations per...
How To Install Oracle Database 10g XE in Oracle? To install 10g universal edition, double click, Ora...
What Are the Underflow and Overflow Behaviors on FLOAT Literals in SQL Server Transact-SQL? If you e...