Get a first look at what's coming. The Developer Passport Australia Release Preview kicks off March 12. Dive in! 

Data load to service catalog request item table

MuppuriNagaraju
Tera Contributor

Hello Everyone,

I am facing the issue with data load. When i am uploading the data into sc_req_item table. The file fields are not showing in the target table(RITM). But I can see same fields in service portal(catalog). but in some RITM records I can see that fields in variable section of RITM records. But when i trying to assist mapping I can not see that fields in mapping assist. what can i do. can anyone help me with data load to RITMs.

2 REPLIES 2

Ankur Bawiskar
Tera Patron

@MuppuriNagaraju 

I shared blow for this in past, check that

Data load and transform via Catalog Item 

share your current config screenshots, what debugging did you do

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

Tanushree Maiti
Tera Sage

Hi @MuppuriNagaraju 

 

The variables are not appearing in the Mapping Assist tool because catalog variables are not stored as columns on the sc_req_item table. Instead, they reside in related tables such as sc_item_option etc, which means they cannot be directly mapped using a standard sc_req_item transform map.

 

Easiest could be ,

If you are generating these requests from a script, use the Cart API to submit the item with data

 

Create Requested Item from Transform Script

When: onBefore
Script:
var cart = new Cart();
// add in cart, substitute your cat item sys_id
var item = cart.addItem('00000000000000000000000000000000');

//Set Variables in your Cart Item
var cartmsg = "Import Set: " + source.sys_import_set.table_name +', Datasource:'+ source.sys_import_set.data_source;
cart.setVariable(item,'comments',cartmsg);

var rc = cart.placeOrder();

 Refer: https://www.servicenowelite.com/blog/2014/2/6/request-generation-methods

 

Please mark this response as Helpful & Accept it as solution if it assisted you with your question.
Regards
Tanushree Maiti
ServiceNow Technical Architect
Linkedin: