Sep 23, 2024
detamoov supports a wide range of time and date-time formats to accommodate diverse data requirements. The following list provides examples of commonly used formats, ensuring flexibility and compatibility in your applications.
Time-Only Formats
These formats represent time alone, without any date component.
- hh: Hour (12-hour format, no leading zero) (e.g., 5)
- HH: Hour (24-hour format, no leading zero) (e.g., 17)
- hhmm: Hours and minutes in 12-hour format (e.g., 0530)
- HHmm: Hours and minutes in 24-hour format (e.g., 1730)
- hhmmss: Hours, minutes, and seconds in 12-hour format (e.g., 053015)
- HHmmss: Hours, minutes, and seconds in 24-hour format (e.g., 173015)
- hhmmssfff: Hours, minutes, seconds, and milliseconds in 12-hour format (e.g., 053015123)
- HHmmssfff: Hours, minutes, seconds, and milliseconds in 24-hour format (e.g., 173015123)
- hh: Hours and minutes, separated by a colon, in 12-hour format (e.g., 5:30)
- HH: Hours and minutes, separated by a colon, in 24-hour format (e.g., 17:30)
- hh:mm: Hours, minutes, and seconds in 12-hour format (e.g., 5:30:15)
- HH:mm: Hours, minutes, and seconds in 24-hour format (e.g., 17:30:15)
- hh:mmfff: Hours, minutes, seconds, and milliseconds in 12-hour format (e.g., 5:30:15123)
- HH:mmfff: Hours, minutes, seconds, and milliseconds in 24-hour format (e.g., 17:30:15123)
- hh tt: Hours and minutes in 12-hour format with AM/PM (e.g., 5 AM)
- hh:mmtt: Hours, minutes, and seconds in 12-hour format with AM/PM (e.g., 5:30:15 PM)
- hhtt: Hours, minutes, seconds, and milliseconds in 12-hour format with AM/PM (e.g., 5:30:15123 AM)
Date-Only Formats
These formats represent date alone, without any time component.
- M/d/yyyy: Month, day, and full year (e.g., 8/23/2024)
- MM/dd/yyyy: Two-digit month, day, and full year (e.g., 08/23/2024)
- d/M/yyyy: Day, month, and full year (e.g., 23/8/2024)
- dd/MM/yyyy: Two-digit day, month, and full year (e.g., 23/08/2024)
- yyyy/MM/dd: Full year, month, and day (e.g., 2024/08/23)
- yyyyMMdd: Full year, month, and day, without separators (e.g., 20240823)
- MM/dd/yy: Two-digit month, day, and two-digit year (e.g., 08/23/24)
- M/d/yy: Month, day, and two-digit year (e.g., 8/23/24)
- dd-MMM-yyyy: Two-digit day, three-letter month abbreviation, and full year (e.g., 23-Aug-2024)
- MMM d, yyyy: Three-letter month abbreviation, day, and full year (e.g., Aug 23, 2024)
Date-Time Formats
These formats combine both date and time components.
- M/d/yyyy hhtt: Month, day, year, hours, minutes with AM/PM (e.g., 8/23/2024 02:30 PM)
- MM/dd/yyyy hh:mm tt: Two-digit month, day, year, hours, minutes, seconds with AM/PM (e.g., 08/23/2024 02:30:45 PM)
- MM/dd/yyyy HH:mm: Two-digit month, day, year, hours (24-hour), minutes, and seconds (e.g., 08/23/2024 14:30:45)
- yyyy/MM/dd HH:mm: Full year, month, day, hours (24-hour), minutes, and seconds (e.g., 2024/08/23 14:30:45)
- yyyy-MM-dd HH:mm: Full year, month, day, hours (24-hour), minutes, and seconds with hyphen separators (e.g., 2024-08-23 14:30:45)
- yyyyMMdd HHmmss: Full year, month, day, hours, minutes, and seconds without separators (e.g., 20240823 143045)
- dd-MM-yyyy hh tt: Day, month, year, hours, minutes with AM/PM (e.g., 23-08-2024 02:30 PM)
- dd-MMM-yyyy HH:mm: Day, abbreviated month name, year, hours (24-hour), minutes, and seconds (e.g., 23-Aug-2024 14:30:45)
- M/d/yy hh:mm tt: Month, day, year (two-digit), hours, minutes, seconds with AM/PM (e.g., 8/23/24 02:30:45 PM)
- yyyy-MM-ddTHH:mmfff: ISO 8601 format with milliseconds (e.g., 2024-08-23T14:30:45.123)
- yyyy/MM/dd hh:mmfff tt: Full year, month, day, hours, minutes, seconds, milliseconds, and AM/PM (e.g., 2024/08/23 02:30:45.123 PM)
Notes:
hh
vsHH
:hh
is the 12-hour format, whileHH
is the 24-hour format.tt
: Thett
format is used for the AM/PM marker in the 12-hour clock.- Separators: Common separators include
/
,-
,:
as well as spaces. - Milliseconds: Represented as
fff
, can be included when more precision is needed.
This list illustrates a broad range of commonly supported formats, though it is not exhaustive and may vary based on specific use cases or custom requirements.