Some fields not importing from XML when using Import Sets

jfarrer
Mega Guru

I have an XML feed that I am trying to consume using Import Sets but it is not getting all of the data. As near as I can tell, it is only looking at the XML elements that exist in the first record, but not all of the elements exist in the first record such as address information, but in later records they are there. It only created and populated the fields that exist in the first record. When I made a custom example file with the second record and tried it with that then it created and populated the fields just fine.

Here is an example:


 <ROW>
   <ID>1887</ID>
   <LAST_NAME>EXAMPLE VENDOR</LAST_NAME>
   <CUST_TYPE>VENDOR</CUST_TYPE>
   <BILL_REFERENCE>C123456</BILL_REFERENCE>
   <TAX_CODE>State</TAX_CODE>
   <STATUS>1</STATUS>
   <BILLING_CYCLE>V</BILLING_CYCLE>
   <CUST_NO>C123456</CUST_NO>
 </ROW>
 <ROW>
   <ID>1580</ID>
   <LAST_NAME>ANOTHER ONE</LAST_NAME>
   <FIRST_NAME>JOHN DOE</FIRST_NAME>
   <CUST_TYPE>VENDOR-NONTAXABLE</CUST_TYPE>
   <BILL_REFERENCE>C654312</BILL_REFERENCE>
   <TAX_CODE>None</TAX_CODE>
   <STATUS>1</STATUS>
   <BILLING_CYCLE>V</BILLING_CYCLE>
   <CUST_NO>C654312 DOE</CUST_NO>
   <ADDR1>123 COUGAR WAY</ADDR1>
   <ADDR2>#1234</ADDR2>
   <CITY>PROVO</CITY>
   <STATE>UT</STATE>
   <ZIP>84602</ZIP>
 </ROW>


I have a work around in place in this case and I know I could manually retrieve and import the data but I don't think I should have to do that.

Any thoughts?

Thanks,
10 REPLIES 10

Jay Uttanoor
Tera Contributor

Based on the Snow documentation this seems to be a system property that defaults to 10 nodes, if the xml has more than 10 nodes and the field/value is not within the 10 nodes Snow does now auto create the Field. Hope this helpss

https://docs.servicenow.com/bundle/quebec-platform-administration/page/administer/import-sets/reference/r_FileTypeDataSource.html

glide.db.impex.XMLLoader.max.scan_nodes