How to combine an advanced reference qualifier with a simple encoded query
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2019 10:54 AM
Community,
I need to update our assignment group reference qualifier for Change Management. Obvisouly I will need to do a dictionary override so that it is just for Change.
Can I do this below
javascript:new BackfillAssignmentGroup().BackfillAssignmentGroup() + typeNOT LIKE0c32e84cdbc95300ec5a70c08c961979
I am getting all the assignment groups now.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2019 02:09 PM
What do you see if you navigate to the following URL in your instance? If this works, then the ref qual I provided should work. If it doesn't, then you need to set the correct filter manually on the group table and then copy that query to use instead.
https://YOURINSTANCENAME.service-now.com/sys_user_group_list.do?sysparm_query=typeNOT LIKE0c32e84cdbc95300ec5a70c08c961979
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-27-2019 06:57 AM
Hi Mark,
When I navigate to the URL with my instance name I get the group table list filtered by type does not contain Approval. I'm getting the correct list.
I agree, i thought my original ref qual should have worked, but you pointed out the '^' needed to be added. This is weird.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-27-2019 07:10 AM
The ‘^’ is just an ‘AND’ for the condition. It needs to be there for sure because otherwise it will just add on to the comma-separated list of sys_ids that the current ref qual function returns. I just noticed something from your original post though. It looks like you’ve got a space in ‘NOT LIKE’. Can you eliminate that space and try again? To be absolutely sure, just right-click the breadcrumb link from your filtered list with the type filtering correctly and use that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-27-2019 11:47 AM
I saw that and re-copied the query and it is putting the space. Just for testing purposes I just did a 'contains' so that I could just get typeLIKEf429f94c0a0a3c9801ecd71fa6749366 (which is a different filter condition but wanted to test).
Still no results. I guess I will have to write a new script include for Change Only.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2019 11:04 AM
Hi,
Just keep the 2nd condition into quotations and it should work.
Mark the comment as helpful and correct if it worked.