Use Attachment on RITM to Associate CIs via Import Set

fcaruso123
Tera Expert

Have a catalog item that accepts a spreadsheet as an attachment containing a list of CIs to decommission. Built a flow that automates the running of the data source (attachment), import set and transformation map to add each row as a related Impacted CI on the RITM.  For now, I hard coded a RITM number in the transformation map to use when it creates each Impacted CI record.

 

The issue I have is how to get the RITM number into the transformation map so that each CI is related to the newly created RITM?

 

Thank you

Frank

 

3 REPLIES 3

Antoni Zahariev
Tera Guru

As you have a flow, it should be possible to update the RITM number to all the records in the Import set table by doing a lookup on the Import Set Number.

fcaruso123
Tera Expert

The issue would be getting in front of the flow that triggers the data source to load the newly attached spreadsheet. I trigger a scheduled job which creates the import set, loads the rows from the spreadsheet and runs the transformation map. There is no place to update the import set records before the transformation runs.

fcaruso123
Tera Expert

I changed the method used to parse the spreadsheet. I was using a Flow that would copy the attachment from the RITM to the Data Source table and then use a scheduled job to process the import set.

 

I changed the Flow to call an Action which receives the RITM as input and a Script object to parse the attachment. It then returns the list of asset names as a string array where a for loop can lookup each asset and create the task_cmdb_ci_service record associated to the RITM.

 

Thanks for the assistance.