HSETPT: Inserting a Component Into a Date-Time Value

How to:

The HSETPT function inserts the numeric value of a specified component into a date-time value.

Syntax: How to Insert a Component Into a Date-Time Value

HSETPT(datetime, 'component', value, length, output)

where:

datetime

Date-time

Is the date-time value in which to insert the component.

component

Alphanumeric

Is the name of the component to be inserted enclosed in single quotation marks.

value

Integer

Is the numeric value to be inserted for the requested component.

length

Integer

Is the length of the returned date-time value. Valid values are:

  • 8 indicates a time value that includes one to three decimal digits (milliseconds).
  • 10 indicates a time value that includes four to six decimal digits (microseconds).
  • 12 indicates a time value that includes seven to nine decimal digits (nanoseconds).
output

Date-time

Is the returned date-time value whose chosen component is updated. All other components are copied from the source date-time value.

WebFOCUS

Feedback