How to: |
The HMIDNT function changes the time portion of a timestamp in date-time format to midnight (all zeroes by default). This allows you to compare a date field with a timestamp in date-time format.
HMIDNT(timestamp, length, output_format)
where:
Date-Time
Is the timestamp whose time is to be set to midnight.
Integer
Is the number of characters returned as the timestamp. Valid values are:
Date-Time
Is the timestamp whose time is set to midnight and whose date is copied from timestamp.
This example converts the character string (20040229 13:34:00) to a timestamp, which is assigned to DTM:
DTM/HYYMDS = HINPUT(14, '20040229 13:34:00', 8, DTM);
This example resets the time portion of DTM to midnight and assigned the timestamp (02/29/2004 00:00:00) to DTMIDNT:
DTMIDNT/HMDYYS = HMIDNT(DTM, 8, DTMIDNT);
iWay Software |