Finding the agent who was the last to update the ticket

3 コメント

  • McCabe Tonna
    コメントアクション Permalink

    Carl,

    Would you be okay with changing the assignee to the current agent every time they update a ticket?

     

    0
  • Vincent Leong
    コメントアクション Permalink

    I am also interested to export a list of zendesk tickets to include the last updater, regardless whether end-user, assignee or requester?

    0
  • Amy Dee
    コメントアクション Permalink

    Hi Carl! Hi Vincent! This type of report should be possible, but it has some caveats. The big one is timing: Insights is not a real time platform. You can only report on the most recent update at the time of the latest data sync. Even on an Enterprise account, data could be delayed over an hour. If you need to see the latest update in real time, I recommend using Views instead.

    For an Insights report, you need to find the update with the most recent timestamp for the ticket. Fortunately, there are default Facts for those timestamps, so you just need to find where they match. You can start with something like this:

    • SELECT COUNT(Ticket Updates) WHERE (SELECT MAX(Ticket updated (minutes)) BY Ticket Updates) = (SELECT MAX(Ticket updated at (minutes)) BY Ticket Id) AND Ticket Status <> Deleted 

    This counts updates where the timestamp of the update is equal to the most recent update timestamp for the ticket (and the ticket is not deleted). 

    Please note: there is a small but critical difference between Ticket updated (minutes) (for ticket updates) and Ticket updated AT (minutes) (for tickets). You need to use both in this recipe, so make sure you have them in the right places. They appear under different headers in the Elements list, which should help you remember which is which:

    This metric counts updates, so it works with (Event) dates and the Updater and Updater Role attributes. That should help you find tickets where the most recent updater (as of the latest sync) was an agent or an end-user. You could combine it with the User (requester) and/or Ticket Assignee attributes to find agents updating tickets they aren't assigned to.

    For more information, check out these articles on building metrics for the events model (for narrowing down an event-based report) and finding the duration between events (for working with update timestamps).

    Please note: These metrics are for demonstration purposes only. Zendesk doesn't support custom code. I can't guarantee them for all use cases, and I strongly recommend that you audit your results.

    I hope this helps! Happy reporting!

    0

ログインしてコメントを残してください。

Powered by Zendesk