How to Compare Application Configurations Across Different Application Scopes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Hello everyone,
I am currently rebuilding an existing ServiceNow application in a different application scope.
For example:
Existing application: App_A
New application: App_B
Both applications exist in the same ServiceNow instance but have different application scopes.
The applications contain approximately 20 application files, including:
Catalog Items
Flows
Client Scripts
Script Includes
Business Rules
I was able to copy the flows, but the other application files were recreated manually by referring to the existing application's configurations.
Therefore, I would like to verify that the new application has been configured correctly, without any missing settings or unintended differences.
In particular, I would also like to compare Catalog Item variable configurations, such as variable types, mandatory settings, default values, and choices.
My questions are:
Is there an efficient way to compare application configurations across different application scopes within the same ServiceNow instance?
Are there any out-of-the-box features in ServiceNow that can help with this comparison?
I am also considering exporting the configurations as XML files. Would this approach allow me to compare all relevant settings, including Catalog Item variables and their related configurations?
My goal is to compare the current configurations of both applications, rather than their update histories.
We are using the Australia release.
Any suggestions or best practices would be greatly appreciated.
Thank you in advance!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Hi,
Short answers to your three questions:
1 and 2: No - there is no out-of-the-box feature in the Australia release that compares two different applications/scopes side by side as current configurations. The compare tools that exist (update set / version "Compare to Current", update history) compare different VERSIONS of the same record - same sys_id, same file. Because your App_B files were recreated manually, they have new sys_ids, new scope values and different scope prefixes, so those tools have nothing to pair them with. They will not tell you that App_A's business rule X and App_B's business rule Y differ.
3: Yes - XML export plus a text diff is the reliable approach for about 20 files, and it does cover catalog variables, but only if you set it up as follows:
- Pair records by TYPE + NAME, never by sys_id. Start from the Application Files list (sys_metadata) filtered by each scope, grouped by file class (sys_script, sys_script_client, sys_script_include, sc_cat_item, sys_hub_flow, etc.), and make a pairing checklist. A file that has no pair on the other side is your first finding - a missing or accidentally extra file.
- Export the UNDERLYING record for each file (form/list > Export > XML on its own table), not just the sys_metadata wrapper row.
- For Catalog Items, the item XML alone is NOT enough: variables live in their own records. Also export, per item, its variables (item_option_new - this is where type, mandatory, default value and order live), the variable set membership if you use variable sets, and the choice lists for select variables (question_choice - label, value, order, inactive). Then diff variable-by-variable matched on variable name + order.
- Normalise the XML before diffing, or every file will look different: strip/replace sys_id, sys_scope, sys_package, sys_created_by/on, sys_updated_by/on, sys_mod_count, and the scope prefix in script include / API names (the App_B file will carry the App_B prefix). Pretty-print/sort the XML and diff in a proper diff tool - after normalisation, the remaining differences are the real configuration differences: conditions, script bodies, active flags, defaults, mandatory flags, choices.
- Flows are the one weak spot: the flow record's XML contains the flow definition in a form that diffs poorly. For the flows you copied, open the two versions side by side in Flow Designer and compare trigger, inputs and action order there, and use the XML diff only as a completeness check.
So: build the type+name pairing list, XML-export each underlying record plus the catalog child records, normalise the volatile fields, then diff. For about 20 files that is practical and it will catch exactly the kind of missed variable setting you are worried about.
