Introduction to Date/Time Formats: %DT
NOTE: This introduction pertains to all %DT calls.
%DT is used to validate date/time input and convert it to VA FileMan's
conventional internal format:
YYYMMDD.HHMMSS
Where:
- YYY—Number of years since 1700 (hence always 3
digits)
- MM—Month number (00-12)
- DD—Day number (00-31)
- HH—Hour number (00-24)
NOTE: If HH is 24, then there cannot be any minutes (MM), or
seconds (SS) indicated.
- MM—Minute number (00-59)
NOTE: If MM is 00 and no value for seconds (SS) is indicated,
then minutes (MM) are ignored.
- SS—Seconds number (01-59)
This format allows for representation of imprecise dates, such as JULY
'78 or 1978, which would be equivalent to 2780700 and 2780000, respectively.
Dates are always returned as a canonic number (i.e., no trailing Zeroes
after the decimal).
The following are the date/time-related APIs:
- X
^DD("DD"): Converts Internal to External Date Format
- DT^DIO2: Writes External Date from Internal
- ^%DT:
Validates Date/Time Input and Converts to Internal Format
- DD^%DT:
Converts Internal to External Date Format
- ^%DTC:
Returns Number of Days between Two Dates
- C^%DTC:
Adds/Subtracts Days and Returns VA FileMan Date and $H Format
- DW^%DTC:
Converts VA FileMan Date to $H Format and Outputs Name of the Day
- H^%DTC:
Converts VA FileMan Date to $H Format
- NOW^%DTC:
Returns Current Date/Time in VA FileMan and $H Formats
- S^%DTC:
Converts Time into Decimal Part of VA FileMan Internal Date
- YMD^%DTC:
Converts $H to VA FileMan Format
- YX^%DTC:
Returns Printable and VA FileMan Internal Formats from $H
- DT^DILF():
Date Converter
Reviewed/Updated: June 2026