Hello Community
In an Enterprise designer dataflow, I am try to convert a String date : 2019-10-07T00:00:00 to a datetime format
I use a transformer stage in which I have set a script with this
treatment :
data['CREATIONDATE_datetime'] = stringToDate(data['Root.GoldenCustomer.CREATIONDATE'] , "yyyy-MM-dd'T'hh:mm:ss");
But when running the dataflow in inspection mode I have this error :
Exception: CANDIDATE_QUERY_odu2-Transformer threw StageException: com.g1.dcg.server.dataflow.stages.transformer.InvalidTransformDefinitionException: 'Custom Transform (Custom Transform CreationDate)' failed: No signature of method: static com.g1.dcg.server.dataflow.stages.transformer.customfunction.impl.ExtendedDateTimeFunctions.stringToDate() is applicable for argument types: (com.pb.spectrum.api.datetime.DateTime, java.lang.String) values: [2019-10-07T00:00:00, yyyy-MM-dd'T'hh:mm:ss] Possible solutions: stringToDate(java.lang.String, java.lang.String), stringToTime(java.lang.String, java.lang.String), stringToDateTime(java.lang.String, java.lang.String)
Any idea what would be a good convert function and syntax ?
thanks in advance
------------------------------
Giang Pham-Dac
Data Manager
L'Occitane International SA
Plan-Les-Ouates
------------------------------