Software Deployment Question

K1000 rule:Open a ticket automatically

12/17/2014 1637 views
I dont know if it is able but what i want is an automatically ticket from monday to friday at 15:30 in one of my queues.
I know that i have to select the email address of my servicedesk and send there the notification, in this way it will open a ticket, but what i dont figure out is the rest of the field and tables that i have to select, if i have to select any.
my code doest give me errors, but it doesnt send any email at all.

->Select SQL

select  1, 'servicedesk@mycompany.br' as email_servicedesk


where curtime() = '15:30:00'
and DAYNAME(NOW()) NOT IN ('Saturday','Sunday')  /* not the weekend */

->checkbox sending email
Coluna contendo endereços de e-mail: email_servicedesk
3 Comments   [ + ] Show comments


  • if i change the code the way im gonna show and i put my email, it sends me the email perfectly. if i put the email for my servicedesk, 'the last register of execution' says that the email has been sent, but it is nowhere.

    select 1, 'servicedesk@mycompany.br' as email_servicedesk

    from HD_QUEUE

    where DATE(NOW())= '2014-12-17'
    and DAYNAME(NOW()) NOT IN ('Saturday','Sunday') /* not the weekend */

    any ideas????
    Thank you!!
    • Why don't you use the SQL update area to create a ticket?

      You can use the INSERT INTO command. Be careful though since doing this wrong can damage your database.
  • thank you for the answer but insert into in which way???i dont see the point, i dont see how im gonna create a ticket.
    • you can create a new ticket by inserting a new row in the HD_TICKET table with the proper parameters. That's how all tickets get created, you're just skipping the application layer and going straight to the database.

      for example:
      insert into HD_TICKET (TITLE, HD_QUEUE_ID)
      values('New Ticket', 1)

      would make a ticket in queue 1 with just a title of New Ticket. It would not have a create date or anything. You can add that in to your insert statement and create a ticket this way.
  • woww thank you very much!!! i see what you say already!! thats perfect! im gonna test it now

Be the first to answer this question

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