Import set-Ensure mandatory fields are filled in excel sheet

G Balaji
Kilo Guru

Hi,

We're upoading data to SNOW custom table through import set staging tables from excel file. 

We wanted to make sure values are available for all mandatory fields in the excel file before data gets inserted into SNOW table. If a field value is missing in excel file, an error message should be shown to end-user and record shouldn't be inserted into our custom table.

How to implement this?

1 ACCEPTED SOLUTION

Try using source.your_field_name_in_source.

View solution in original post

9 REPLIES 9

Try using source.your_field_name_in_source.

This doc page also helped me a lot

https://docs.servicenow.com/bundle/kingston-application-development/page/script/general-scripting/concept/immediately-invoked-function-expressions.html?cshalt=yes

Rajesh Mushke
Mega Sage
Mega Sage
Hey Balaji, Do want to show error mesaage before uploading the sheet or else after uploading the sheet? Let me know if you need more help Thanks, Rajashekhar Mushke Community Leader - 18


Thanks,
Rajashekhar Mushke
Rising star : 2022 - 2024
Community Leader -2018
Connect me on LinkedIn : Rajashekhar Mushke

G Balaji
Kilo Guru

Hey Rajashekhar,

Yes, an error message should be shown when a mandatory field is missing in the excel sheet.

have you checked this article ? it's known error that  "Enforce mandatory fields" is not working as expected"

https://hi.service-now.com/kb_view.do?sysparm_article=KB0685288