The Problem
Date information from the source is represented as a text string, with the format YYYYMMDD. We need the information to be represented as a date-time data type in Sisense.
The Solution
This will utilize a custom field to convert the value. The original date value needs to be defined in the ElastiCube as a text data type. The following code gets the correct results:
CreateDate(
ToInt(Substring([Date Text],1,4)),
ToInt(Substring([Date Text],5,2)),
ToInt(Substring([Date Text],7,2))
)
The attached .ecdata file provides data that demonstrates this functionality.
Download:
See Also
Convert Integer Date to Date-time format