Asset import set issue

amber_martin
Kilo Contributor

Hello.   I am having issues with my import sets when using importing assets. Hopefully someone can please give me insight.   My version of SN is Helsinki. The models were already created before import. I imported some laptops using transform map and mapped my fields. After import I checked my data and the Company, Model, and Class were not recognized.   Those fields were blank therefore the Display Name was not created correctly so they did not go to the already created model. The class was populated as Product Model instead of what I specified as Hardware Model.   I believe those fields didn't import correctly because they are referenced fields. Is there a way to import those fields without scripting or is there something else I am missing?

7 REPLIES 7

akash_mehta
ServiceNow Employee
ServiceNow Employee

Amber:   A couple of screen shots may help us help you.   However, I will take a stab first and see where we get.



In your transform map for the asset - Does the values in your import data match up to the "display value" of the reference table?   If not, is there another field it could "coalesce" against?   For instance, if in your "excel" file you have the model number field, you will need to put the field name from the model table in the "referenced value field name" on the field map.Screen Shot 2017-05-26 at 2.59.52 PM.JPG



So in the example above - if I am doing a straight mapping of the model id field from the cmdb_ci_computer table I need to ensure my value is equal to the model table display value or identify the reference field i want to use to match (i.e. model_number).



This is the same for all three of your fields - because they are all references.   Also, consider changing the choice action to ignore or reject if it doesn't find a match.



Hope that helps.



-Akash


So I think I am asking the wrong question.   I need to import the assets to the alm_hardware table but I need those assets to go the correct models that I have already created. When creating the transform map from the alm_hardware template I do not see the fields for the model or class as a field option to import to. Without those fields, the only information about the asset is the model.   Which then the Display Name is incorrect.   On the hardware form those fields are referenced fields Model (cmdb_hardware_product_model), Company (core_company), and Class(cmdb_hardware_product_model) that create the display name. The class mapped to the product model as well.



How do I import these assets and get all the information display and with Hardware Model class?


Amber:   Again a couple of screen shots would be helpful.



So I have created a transform map against the alm_hardware table:


Screen Shot 2017-05-26 at 3.35.52 PM.JPG


Make sure the target table is correct.



Then create the mapping:


Screen Shot 2017-05-26 at 3.36.31 PM.JPG



Again against the Hardware table the Model field should be available.



I hope that helps.


I map the fields find_real_file.png



But this is what displays:



find_real_file.png


This is what I need it to look like:


find_real_file.png


The Display name is formulated from the Name and Manufacturer fields which are from the cmdb_hardware_product_model table so because that the import creates an incorrect Display name. So I am not sure how to import these asset correctly with the correct information.