Wednesday, June 15, 2022

Oracle SQL TIMESTAMP Data Type

1.    The TIMESTAMP data type is an extension of the DATE data type.

2.    It stores the year, month, and day of the DATE data type, plus hour, minute, and second values.

3.    This data type is useful for storing precise time values and for collecting and evaluating date information across geographic regions.

4.    Specify the TIMESTAMP data type as follows:

 

       TIMESTAMP [(fractional_seconds_precision)]

 

where fractional_seconds_precision optionally specifies the number of digits Oracle stores in the fractional part of the SECOND datetime field.

When you create a column of this data type, the value can be a number in the range 0 to 9. The default is 6.

 

TIMESTAMP 'YYYY-MM-DD HH24:MI:SS.FF'
TIMESTAMP '2022-01-31 23:59:59.10'

No comments:

Post a Comment