Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
My input from database is having "date" in string datatype with size 50, which is sending date in yyyy-mm-dd format. I want to store it at the destination in String(50) with mm-dd-yyyy format. Solution please.
i shoudn't drop records, because after this transmission those blank date fields will be having a data thru front end. I need to pass these blanks. Hence i did like below in tMap but it didnt work. Please suggest.
row2.DiagnosisActivityStartDate == "" ? "" : TalendDate.formatDate("MM-dd-yyyy",TalendDate.parseDate("yyyy-MM-dd",row2.DiagnosisActivityStartDate))
"".equals(row2.DiagnosisActivityStartDate) ||
row2.DiagnosisActivityStartDate == null ? "" : TalendDate.formatDate("MM-dd-yyyy",TalendDate.parseDate("yyyy-MM-dd",row2.DiagnosisActivityStartDate))
Wow TRF... it worked.. Thanks again
Hello TRF,
Can you please explain the statement you have given for the solution?
"".equals(row2.DiagnosisActivityStartDate) ||
row2.DiagnosisActivityStartDate == null ? "" : TalendDate.formatDate("MM-dd-yyyy",TalendDate.parseDate("yyyy-MM-dd",row2.DiagnosisActivityStartDate))
It worked actually, but the output excel's cell is in "General" format and i am expecting in "Custom" format cell with MM-DD-YYYY option (just like the attached image) then only the formula will pick this cell for calculation. Please guide