6. Date / Time date

A date / time data type is used to store any data that is related to date or time.

The tricky thing about date / time is that there are so many ways of showing it. And some countries have a different way of representing a date. For example

9/4/94 in the USA means 4th Sept 94

9/4/94 in the UK means 9th April 94

By using a date /time data type, you can choose the format for how you want your data to be automatically displayed.

For example: 14/05/08, 14 May 2008, 14th May 2008 etc.

Another reason to use a date /time data type is that it can provide some basic validation on the data being entered.

For example, you would not be able to enter the date 31/02/2008 - it would automatically be rejected or return an error message.


challenge see if you can find out one extra fact on this topic that we haven't already told you

Click on this link: Date Time Data Type