/build/static/layout/Breadcrumb_cap_w.png

Systems Management Question


Custom Rule to Sequentially Number Tickets outside of standard ID's

07/21/2020 103 views

So, I think we have something for this, nearly, but I'd like to ask the Brain trust on here first as you may have a better way of doing it or I may be going about it all wrong.

We're creating a Change Request System on the service desk for business-wide changes, and as part of the scope we need the Tickets to be identified separately to the 'standard' service desk, i.e. not by TICK: identifier. We're using processes for the CR system, so the TICK: numbers would be different between parent and child tickets which would overly confuse matters

The easiest way I could think of to do this is to create a custom rule that appends CR:# at the start of the Title upon ticket creation , with # being a sequential value to give each CR a 'plain' numerical identifier. The child tickets will be inheriting the Parent ticket's title.

I'm thinking of (roughly) the following SQL to do this;

UPDATE HD_TICKET

SET TITLE = 'CR# ' + CONVERT(VARCHAR(10),(SELECT COUNT(*) + 1 FROM HD_TICKET WHERE HD_QUEUE_ID = CRQUEUEIDNUMBER AND IS_PARENT = True))+ ' ' + TITLE


Good idea? Bad Idea? Better way of doing this? I'm all ears.

2 Comments   [ + ] Show comments

Comments

  • Have you considered using a different queue for your CRs? This would allow you to see all your CR tickets separately. You could name the queue "CR" and then pre-pend the queue name in ticket emails and reports. Just an idea...
    • The CR's are indeed in a different queue. In emails and reports that would work, but not on the ticket itself; the users need a unique identifier for these which aren't part of the TICK:ID system., and I'd rather have the system create these itself than trust users to +1 on the previous CR#.
  • This content is currently hidden from public view.
    Reason: Removed by member request For more information, visit our FAQ's.
  • Oh, now I see. I should have read your post more carefully. Hopefully, someone else will have a better idea if your SQL statement will work. Good luck!

All Answers

0

Bad idea, the Hd_ticket tableĀ is using the ID number as the ticket ID, messing with data in this table is basically asking for trouble. If your only reason behind wanting to prefix the id with a CR as you find the TICK confusing, the TICK text enables the SMA to identify in long emails as emails that should be actioned. I am assuming that you will still need email functionality for your Change Queue?



Answered 07/23/2020 by: Hobbsy
Red Belt

  • I don't want to touch the ID, that is I believe the PK for the table, and would, as you say, be an apocalyptically bad idea to mess with. I'm looking to append the CR:# to the Title field.

    So the email identifier if it's in "ticket_id - ticket_title" format would be unchanged, as it'd be "TICK:#-CR:# Title", and wouldn't mess with the email routing.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ