Thinking of it, I would do the following:
NOTE: TAKE A BACKUP BEFORE APPLYING THE BELOW
Link System>Group>Support Group to Incident Management>Incident (One to one relationship)
Link System>Group>Support Group to Incident Management>Assignment (One to one relationship)
Then add the new support group field into the assignment window and remove the group field. Then apply the following calculation on the attribute "Current Assigned Group" which is under Incident Management>Incident:
static def GetAttributeValue(Incident):
Value = ''
Assignment = Incident.Assignments.Latest()
if Assignment.SupportGroup != null: Value = Assignment.SupportGroup.Title
Once this is done, Go to your Incident search query and add the Support Group into the criteria.
I went through this step by step (very easy to follow, BTW) and unfortunately it never pulls any kind of result when I use it to search. I went back to the assignment window and made sure I had replaced the group field that originally existed and my changes had stuck, so I am not sure why it's not pulling back any results. Unfortunately I don't think this approach will work for us anyway because it would not update older Incidents and anything that was submitted prior to promotion of this change would no show up if this new attribute was used to search. I am thinking that the solution I desire might not be possible without a working filter on the existing attribute.
1 of 1 people found this helpful
We can work around this by applying a script to copy the old data into the new field on the SQL Database. Because the same old values do exist in the new Support Group field so it should it
You are simply using the wrong attributes in your query. You are using the Calculated String attributes "Current Assigned Analyst" and "Current Assigned Group" note that these are simply string fields that are calculated and will never show as a dropdown. Therefore, you should be using in your query criteria, Current Assignment->Group and Current Assignment->User. Then it will display as a dropdown.
Lead ITSM Consultant
I wanted to suggest that at the beginning but I noticed that the current assignment > Group is listing all of the group in my environment. That's why I think using the Support Groups is a good solution for this.
I believe that you can accomplish this by relating Support Group to the Incident Object. The subsequent field created would then be set as a calculation that will grab the latest assigned group from the most current assignment. I would use a couple of if statement to make sure that the latest group is set to avoid errors with the calculation. Since this field is based on Support Group instead of Group, it should be narrowed down to the groups that you are looking for. The calculation would be set as a Before Save calculation, this will work for all newer Incidents. To set this field for all previous Incidents, I would set the calculation as scheduled and run it one time. That scheduled calculation could take some time to run depending on how many Incidents you have. Once it has completed, you can delete the schedule and set the calculation back to Before Save.
I overlooked the part where it is showing suppliers as well. I would do exactly what Jonathan says to do. Will work fantastic.