Question & Answer
Question
Is there a way to import date/time values into TRIRIGA using user-friendly date formats like 'dd/mm/yyyy hh:mm:ss' instead of epoch time?
Cause
All date/time values are stored in the TRIRIGA database as epoch time (number of milliseconds from 01/01/1970 00:00:00 GMT/UTC)
Answer
You can not import a date values directly into a TRIRIGA date/time fields using user-friendly date formats -- you have to import using epoch time.
What you can do instead is import the user-friendly date/time value into a text field in TRIRIGA and then use a workflow to convert the value to epoch time and store that converted value in the corresponding date/time field. One way of doing this is the following:
- Within your Business Object, create a custom text field that you can use to store your date/time value in a user-friendly format such as 'dd/mm/yyyy hh:mm:ss'
- Assuming you are importing your data using Data Integratior, do the following:
- In the Data Integrator header, specify the text field you created to store your user-friendly date/time value
- Create an asynchronous workflow to listen for triUploadHidden actions (or whatever action you choose to associate with your data upload). Have that workflow check to see if the date/time field in the record is null and, if so, to take the the user-friendly date/time specified in your text field and map it as an epoch time value in the actual date/time field.
- When uploading your text file to Data Integrator, specify an action that is in line with what your workflow expects. IBM typically recommends using triUploadHidden, but you could use triCreateDraft or even create a cstUpload action which could be used to make the choice show up first in the list.
Was this topic helpful?
Document Information
Modified date:
17 June 2018
UID
swg21976407