LESSON 12Dates and Time in SQL
In this lesson, you will learn about the nature of dates and time in SQL and how they are stored and used in a relational database. Not only will we discuss the DATETIME
data type in more detail; we will show how some implementations utilize dates, explain some of the common rules, and show how to extract the date and time in a desired format. By the end of this lesson, you should understand the following about dates and time in SQL:
• How the date and time are stored
• Typical date and time formats
• How to use date functions
• How to perform date conversions
Get Sams Teach Yourself SQL in One Hour a Day, Fifth Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.