Share via


DateTime Data Type

Choose the data type to store values that are both dates and times or only dates. A DateTime value is stored in eight bytes — two four-byte integers.

Visual FoxPro versions 5.0 and later support a strict Date and DateTime format that provides year 2000 compliance. It's recommended that you use strict date formats for all Date and DateTime constants and expressions. For more information about strict date formats, see Year 2000 Date Support.

In both Date and DateTime data types, the following rules apply:

  • {00:00:00AM} is equivalent to {12:00:00AM}, Midnight.
  • {00:00:00PM} is equivalent to {12:00:00PM}, Noon.
  • {00:00:00} to {11:59:59} is equivalent to {12:00:00AM} to {11:59:59AM}
  • {12:00:00} to {23:59:59} is equivalent to {12:00:00PM} to {11:59:59PM}

See Also

CREATE TABLE - SQL Command | Date Expression Creation | Data and Field Types | Date and DateTime Operators