Displaying Formats for datetime, smalldatetime, and date Values

The display format for datetime and smalldatetime values is “Mon dd yyyy hh:mmAM” (or “PM”); for example, “Apr 15 1988 10:23PM”.

To display seconds and milliseconds, and to obtain additional date styles and date-part orders, use the convert function to convert the data to a character string. SAP ASE may round or truncate millisecond values.

Some examples of datetime entries and their display values are:

datetime Entries

Value Displayed

“1947”

Jan 1 1947 12:00AM

“450128 12:30:1PM”

Jan 28 2045 12:30PM

“12:30.1PM 450128”

Jan 28 2045 12:30PM

“14:30.22”

Jan 1 1900 2:30PM

“4am”

Jan 1 1900 4:00AM

Some examples of date entries and their display values are:

date Entries

Value Displayed

“1947”

Jan 1 1947

“450128”

Jan 28 2045

“520317”

Mar 17 1952