Email Alerts for Unassigned Tickets
Hello,
Is there a way I can create a custom alert that will email the helpdesk ticket owners if an unassigned ticket has a comment added to it? I was thinking there would be a way to edit the new ticket alert some how but I'm not familiar with it enough to know exactly what I'm going. Thanks in advance for the help. Here is the new ticket alert we use:
select
HD_TICKET.ID,
HD_TICKET.ID ticket_number, -- $ticket_number
HD_TICKET.TITLE ticket_title, -- $ticket_title
SUBMITTER.FULL_NAME ticket_submitter_name, -- $ticket_submitter_name
SUBMITTER.EMAIL ticket_submitter_email, -- $ticket_submitter_email
CAT.NAME ticket_category, -- $ticket_category
IMPACT.NAME ticket_impact, -- $ticket_impact
PRIORITY.NAME ticket_priority, -- $ticket_priority
STATUS.NAME ticket_status, -- $ticket_status
C.COMMENT, -- $comment
group_concat(OWNERS.EMAIL) as EMAILCOLUMN
from
HD_TICKET
join HD_TICKET_CHANGE C on HD_TICKET.ID = C.HD_TICKET_ID
and C.ID = <CHANGE_ID>
left join USER SUBMITTER on HD_TICKET.SUBMITTER_ID = SUBMITTER.ID
left join HD_CATEGORY CAT on HD_TICKET.HD_CATEGORY_ID = CAT.ID
left join HD_IMPACT IMPACT on HD_TICKET.HD_IMPACT_ID = IMPACT.ID
left join HD_PRIORITY PRIORITY on HD_TICKET.HD_PRIORITY_ID = PRIORITY.ID
left join HD_STATUS STATUS on HD_TICKET.HD_STATUS_ID = STATUS.ID
join HD_QUEUE_OWNER_LABEL_JT HDQOLJT on HD_TICKET.HD_QUEUE_ID = HDQOLJT.HD_QUEUE_ID
join USER_LABEL_JT ULJT on HDQOLJT.LABEL_ID = ULJT.LABEL_ID
join USER OWNERS on ULJT.USER_ID = OWNERS.ID
where
C.DESCRIPTION like '%Ticket Created%'
Answers (1)
Top Answer
Change this line:
C.DESCRIPTION like '%Ticket Created%'
to this:
C.DESCRIPTION not like '%Ticket Created%'
Comments:
-
Thank you. What would I change to make it so it only alerts us if the owner is unassigned (null). - toneal 4 years ago
-
Add:
and HD_TICKET.OWNER_ID = 0 - chucksteel 4 years ago
-
That worked like a charm. Can't believe it was as simple as changing one line.
Thank you so much! - toneal 4 years ago