Should sys_id match across instances for groups?

juan casas
Mega Expert

 

Should the sys id of groups match across all instances (dev,prod,test)?

 

For some reason, we got a group that does not have matching sys ids across the instances,

I send the issue to ServiceNow and they said that this was OK?...... which seem really odd

 

find_real_file.png

 

 

Then we have big time Chuck, AKA ServiceNow OG AKA ServiceNow GOAT with the following post::

find_real_file.png

 

 

Chucks post answer:: https://community.servicenow.com/community?id=community_question&sys_id=7b4f4fe1dbdcdbc01dcaf3231f961981

 

 

servicenow post:: Compare local update sets (servicenow.com)

 

 

 

 

1 ACCEPTED SOLUTION

Mohith Devatte
Tera Sage
Tera Sage

Hello @juan casas ,

so to explain this case its better if you have group sys_ids same across the instances .

Reason: lets say you have createD a group in DEV and you used the sys_id it in some script to compare group sys_id value 

But you have created a same group with same name in TEST or PROD environment with all same configurations but in this case it creates a unique 32 bit sys_id in that particular instance which will not be same as dev 

and when you move your code to test or prod your code might not work because you must have compared with dev group sys_id .

Best practice is export it to xml and then move it other instances instead of creating them in other instances as these are transactional data and not captured

IT ALWAYS MATCHES THE NAME AS THE UNIQUE ONE BUT NOT THE SYS_ID 

PLEASE MARK MY ANSWER CORRECT IF IT HELPS YOU

View solution in original post

5 REPLIES 5

Harish KM
Kilo Patron
Kilo Patron

Hi Yes, SYSID must be same for all 3 instances. Reason these sysids can be used in some scripts or properties or assignment rules. Incase if they different your functionality will break due to sysid mismatch.

I would recommend export the group xml which donot match and import it to sub prod instances and delete the other ones also make sure your scripts and assignment rules have correct group

 

Regards
Harish

Mohith Devatte
Tera Sage
Tera Sage

Hello @juan casas ,

so to explain this case its better if you have group sys_ids same across the instances .

Reason: lets say you have createD a group in DEV and you used the sys_id it in some script to compare group sys_id value 

But you have created a same group with same name in TEST or PROD environment with all same configurations but in this case it creates a unique 32 bit sys_id in that particular instance which will not be same as dev 

and when you move your code to test or prod your code might not work because you must have compared with dev group sys_id .

Best practice is export it to xml and then move it other instances instead of creating them in other instances as these are transactional data and not captured

IT ALWAYS MATCHES THE NAME AS THE UNIQUE ONE BUT NOT THE SYS_ID 

PLEASE MARK MY ANSWER CORRECT IF IT HELPS YOU

Arav
Tera Guru
Tera Guru

For OOB groups, they are usually the same but even if they are different, what SN noted in your original post is true.

For instance, if you promote an SLA record referencing a group in its condition from instance 1 to instance 2 where the underlying sys ids of the group record are different across the two instances, the system will still recognize the group in instance 2 via group name and match it.

Harish KM
Kilo Patron
Kilo Patron

My recommendation would be create groups in Production and have a job run daily to push it to SUB Prod instances this way groups will be automated .

Else create groups in Prod and manually export to sub prod instances.

This way all your sysid will be same.

Regards
Harish