Data prep function | Community
Skip to main content
Level 3
October 3, 2023
Solved

Data prep function

  • October 3, 2023
  • 1 reply
  • 1324 views

Hi team,
Their is any function to convert mentioned datetime value e.g. Sep 25 2023 3:06pm into AEP recommended datetime format like YYYY-MM-DDThh:MM:ss+00:00.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by arpan-garg

Thanks I agree but in case we have these records in once specific attribute then how can we use above function.
like in below one CSV file
 G_Id            D_Datetime 

 5478        Sep 25 2013 3:06pm

7896         Aug 25 2022 5:05pm

 

how can we ingest above D_datetime value in AEP...

As per my knowledge AEP can accept only below format  'YYYY-MM-DDThh:MM:ss+00:00'


Hi @sandip_surse - In that case just use a data prep function and map it to your target attribute in dataset.

date( D_Datetime,"MMM dd yyyy h:mma")

Where D_Datetime is the field in the source csv.

 

1 reply

arpan-garg
Community Advisor
Community Advisor
October 3, 2023

Hi @sandip_surse -"25 2023 3:06pm" Whats the value of month in the date you mentioned?

Level 3
October 3, 2023

Sorry I miss to add 
it's "Sep 25 2023 3:06pm"

arpan-garg
Community Advisor
Community Advisor
October 3, 2023

Hi @sandip_surse - Here is the solution

 

date("Sep 25 2013 3:06pm","MMM dd yyyy h:mma")

Thanks,

Arpan