toDateTime

toDateTime() function is the Standard function available in 200OK.

Description : The toDateTime function converts the input date and time into the specified format.

Syntax : fx_toDateTime(dd-mm-yyyy hh:mm:ss,dd-MM-yyyy HH:mm:ss)

Example : fx_toDateTime(15-02-2022 17:41:25,dd-MM-yyyy HH:mm:ss) returns "2022-02-16T01:41:25.000Z", indicating the updated date and time formatted according to the specified format.

Here we go with simple scenario using the above function.

Scenario : In a logistics system, users convert timestamps into 'yyyy-MM-ddTHH:mm:ss.000Z' format for consistent event logging. They use a function to update timestamps, ensuring data integrity. For example, converting '15-02-2022 17:41:25' to 'yyyy-MM-dd HH:mm:ss' returns '2022-02-16T01:41:25.000Z'.

Request Side :

Response Side :

Last updated