Skip to main content
Sarah Kennedy (Steampunk) 님이 DataWeave in Apex에 질문했습니다

I have the following script: 

%dw 2.0 

input records application/csv 

output application/apex 

--- 

records map(record) -> { 

 IVP_First_Name__c: record.'First Name*', 

 IVP_Last_Name__c: record.'Last Name*', 

 IVP_Middle_Name__c: record.'Middle Name', 

 IVP_Date_of_Birth__c: record.'DOB*' as Date{format : "M/d/yyyy"}, 

... 

 

This works fine except when there is no date entered on the CSV. It just throws an obscure error message and I cannot get into the results to make any changes. The response just shows commas for missing data like  JOE,,,,TRUE 

 

  Is there a way I can define a default value or 'null' for the date in my script above? 

 

Thanks.

답변 1개
0/9000