Derived Field - Extract Time Part
Hey,
I am trying to extract the Year part from my date. The date is of the format MM/dd/yyyy.
It is of string type.
When I try to run the extract row level function, I get an error.
Could someone help me out?
0
-
Hi Dishaa,
This is the Logi Info forum, so your question should be on the Logi Composer platform forum really, however the extract syntax should be as follows:
extract('year', begin_date)
The error is complaining that your start_date field is a string though. You might be able to use the text_to_time function eg:
extract('year', text_to_time(begin_date, 'MM/dd/yyyy'))
...But it may be better to make it a proper datetime field in the database
0
Please sign in to leave a comment.
Comments
1 comment