- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
This blog post might enrage few people, as honestly, I am starting to think the solution I am presenting here is very silly.
I have seen many blogs posts and share utilities allowing you to create GlideRecord queries from encoded queries and list layout.
"Preview in Background Script" Tool
Share App - Get GlideRecord Query from List
Shameless plug - Unlearn Series - Adding a cool encoded query menu
While ServiceNow does provide you with the ability to copy the query from the list and build complex GlideRecord queries fairly quickly, the reverse is not available. More often than not, I end up needing to replicate the filter on the table list while debugging any script. So the below solution will save you few clicks while needing to do so.
Create a UI Context Menu as below.
Name: Paste Query (Your wish)
Order: 10000
Menu: List header
Table: Global
Condition: gs.hasRole("admin")
Script:
var query = prompt("Paste encoded query here");
if(query){
g_list.setFilterAndRefresh(query);
}
If you liked the content, please share, like, bookmark or leave your valuable comments. If you found it silly, ignore
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.