I have rules that pulls the Manager info from LDAP all the way into a custom field (HD_TICKET.CUSTOM_FIELD_VALUE3) in a ticket.  I'm looking for some query help as I'm wanting to create an update query that will update the ticket owner to the manager listed in the custom field.  I'm a little rusty on my scripting so some help would be appreciated.

2 Comments   [ + ] Show Comments

Comments

  • Is HD_TICKET.CUSTOM_FIELD_VALUE3 storing the user ID of the manager or something else (name, username, etc.)?
  • It's storing the managers Full name. I've created the below which seems to do what I need. (Note I'm also moving the ticket to a different queue)

    update HD_TICKET
    SET HD_TICKET.HD_QUEUE_ID = 7,
    HD_TICKET.OWNER_ID = (select USER.ID from USER where FULL_NAME = CUSTOM_FIELD_VALUE3)
    where
    (HD_TICKET.ID in (<TICKET_IDS>))
Please log in to comment

There are no answers at this time

Answers

Answer this question or Comment on this question for clarity