Query Business rule
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-05-2024 03:52 AM
Hello
A small query, if any one has see this on there environment happened any time
We have a Query BR to restrict some Incident. When we moved this Production and this start updating some one ticket., lost if incident where were old got reopened
Has any one see this pattern
As per me query business rule does not update any record, correct me if i am wrong
- Labels:
-
Incident Management
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-05-2024 04:07 AM
Hi @rajesh44853, I haven't observed the mentioned behavior anytime with query business rules. Query business rules are used to restrict the record visibilty and should not be updating the records. However, please check the query business rule script to make sure it doesn't contain 'update' method in it.
Regards,
Sunil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-05-2024 04:11 AM
Hello Sunil
I did a check there is nothing in that BR, its amazed me when something updated the ticket. The problem of ticket updating stopped post disabling the BR
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-05-2024 04:34 AM
Please share your script so we can see if it is related to the BR or not. Without any other information than what you describe, we can only assume something is wrong, but can't help you on what.
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-05-2024 11:06 AM
Appologies for being late
here is the script
if (gs.getUser().isMemberOf('Group1') || gs.getUser().isMemberOf('Group2') || gs.getUser().isMemberOf('Group3') || gs.getUser().isMemberOf('Group4') || gs.getUser().isMemberOf('Group5')) {//show all incident
} else {
current.addEncodedQuery('assignment_group!=f7059095971df5107bbbb7f11153af71^assignment_group!=57199c36870b85505c9921f9cebb3536^assignment_group!=2918d036870b85505c9921f9cebb355e^assignment_group!=6b495076870b85505c9921f9cebb35c2^assignment_group!=94f81036870b85505c9921f9cebb3565^assignment_group!=f478d036870b85505c9921f9cebb356e^NQassignment_groupISEMPTY');
}