Was this page helpful?
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

ISO 8601 Format

SQL Server 2005

In Microsoft SQL Server 2005, you can specify date and time data by using the ISO 8601 format.

This is the format:


The T indicates the start of the time part of the datetime value.

To use the ISO 8601 format, you must specify each element in the format. This also includes the punctuation marks that are shown in the format.

The brackets indicate that the fraction of seconds component is optional. The time component is specified in the 24-hour format.

The advantage in using the ISO 8601 format is that it is an international standard. Also, datetime values that are specified by using this format are unambiguous. Also, this format is not affected by the SET DATEFORMAT or SET LANGUAGE settings.

Following are two examples of datetime values that are specified in the ISO 8601 format:

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2015 Microsoft