Export users from production to dev

VenkataSreC
Tera Contributor

I have some users in production instance that are not available in dev instance I want to export from prod to dev I want only 10 users from prod how to do that 

6 REPLIES 6

Rafael Batistot
Tera Sage

Hi @VenkataSreC 

 

In the sys_user list:

  • Apply your filter (only your 10 chosen users).
  • Right-click the header → Export → XML.

 

This XML export is different from an update set — it will let you import directly into Dev without bringing other unwanted changes.

 

 

Import into Dev. In your Dev instance:

 

  • Go to System Definition → Tables → sys_user.
  • Right-click the header → Import XML.
  • Upload the XML you exported from Prod.

 

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @VenkataSreC 

How to Export and Import Users via XML

In Target Instance

  1. Go to the User table in list view.

  2. Get the 10 users you want in the list view.

  3. Right-click on any field header in the list view.

  4. Select export XML.

In (Dev) Instance

  1. Open the User table in list view.

  2. Right-click on any field header.

  3. Select Import → XML.

  4. Save the file.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Chaitanya ILCR
Kilo Patron

Hi @VenkataSreC ,

 

you can take the XMLs of those records and import them into your dev instance

refer this video for the same 

 

also you can export sys_user_has_role and sys_user_grmember table records if reqiuired

https://www.youtube.com/watch?v=gI3JwXP6vK0

 

Please mark my answer as helpful/correct if it resolves your query.

Regards,
Chaitanya

In this ServiceNow Tutorial, Technical Consultant Laurence Tindall gives a demo on Exporting and Importing Records via XML in ServiceNow. To occasionally migrate data from one instance to another, you can export XML data from one instance and import it to another. This method ensures that all ...

Shashank_Jain
Kilo Sage

Hello @VenkataSreC ,

 

As other community members have already shared:

 Export users from the sys_user table in your Production instance, then import the XML into your Development instance.

However, keep in mind:

 Roles and group memberships are not included when exporting only from the sys_user table.

To fully replicate user access in Dev:

  • Roles
    Export from sys_user_has_role where user = <specific user>
    → Ensures roles  (e.g., itil, admin) are retained.

  • Group Memberships
    Export from sys_user_grmember where user = <specific user>
    → Ensure groups (e.g., support or assignment groups) are retained.

Export and import the following tables for complete user access replication:  sys_user,  sys_user_grmember, sys_user_has_role

 

Hope it works!

If this was helpful, please mark this as accepted solution.

 

Thank you!

 

If this works, please mark it as helpful/accepted — it keeps me motivated and helps others find solutions.
Shashank Jain – Software Engineer | Turning issues into insights