Decoding DMSII Date/Times

The DATABridge Client implements a set of dms_subtype values to decode DMSII items that include the date and time in a single item. Specifically, the DATABridge Client contains values for DMSII ALPHA or NUMBER values that represent the date/time in a variety of ways, such as:

  • Month, day, year, and time of day combined into a twelve-digit (031005112501) or fourteen-digit (03102005112501) number
  • Julian dates and time of day represented as an eleven-digit number (06905112501) or a thirteen-digit number (0692005112501)
  • 48-bit quantities that represent TIME(6), TIME(7), or TIME(60) type data which encode a date and a time

To decode these types of date/time representations into a relational database date/time data type, see Decoding DMSII Date/Time Represented as ALPHA or NUMBER. When using these with SQL Server, you should set the di_options bit DIOPT_Use_LongDate to force the client to use a data type of datetime rather than smalldatetime. When a data type of smalldatetime is used, the client sets the values of seconds to zero (0), as SQL Server rounds the value to increments of .000, .003, or .007 seconds.