Level 1
Level 2
Sign in to Community
Learn more
Sign in to view all badges
Expand my Community achievements bar.
Hi We are having JSON data having Transaction Date attribute but the values in format of 20250122160808(YYYYMMDDHHRRSS).So i need to change to (for Eg 2025-01-22 16:10:58) YYYY-MM-DD HH:RR:SS This format.How i can achieve this using JS code.
Solved! Go to Solution.
Hi @VV7 ,
You can try the below,
vars.jsonTime= '20250122160808'; vars.DateFormat = vars.jsonTime.substr(0,4)+'/'+vars.jsonTime.substr(4,2)+'/'+vars.jsonTime.substr(6,2)+' '+vars.jsonTime.substr(8,2)+':'+vars.jsonTime.substr(10,2)+':'+vars.jsonTime.substr(12,2); logInfo("jsonTime: "+vars.jsonTime); logInfo("DateFormat: "+vars.DateFormat);
View solution in original post
Views
Likes
Replies