Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Can't find duplicate record after xml import

PL_
Tera Contributor

So here is the context.

 

I was trying to move some records from core_company table on my dev instance into the customer_account table on the test instance. To do that I first changed the table tag in xml from

 

<core_company action="INSERT_OR_UPDATE">

 

 to

 

<customer_account action="INSERT_OR_UPDATE">

 

and the improt was successful. However after that I deleted these records on the test instance because I need to improt them again, and this time I also changed the sys_class_name tag from

 

<sys_class_name>core_company</sys_class_name>

 

 to 

 

<sys_class_name>customer_account</sys_class_name>

 

 But this time I'm getting errors saying that there is a duplicate primary key for sys_id. Since I have already deleted the records from the first import I could not find them in both tables.

I have tried using background script to query for the duplicate sys_id and wasn't successful. This issue has been bugging me for a while and is holding back the overall development, so any help is appreciated.

1 REPLY 1

CharanjeetSingh
Tera Contributor

did you found any solution @PL_ , I am also facing the same issue