Automation Rules copie attachment

bricast's picture

I created an automation rule that will take an email that comes in and create two additional tickets. The original email has one or more attachments that need to be added to the other tickets. How can I get the automation rule to copy the attachment to the other to tickets it creates?

jgo's picture

Relatively Complicated

I think it is relatively complicated.
First you would need to set a property on the new ticket through advanced assignment so:

Set: workitem_has_attachments
To: WORKITEM(workitem_has_attachments)

Then you would need to run the Stored Procedure dbo.sp_addattachment which require the following parameters:
@worker_id, @workitem_number, @workitem_version, @set_clause

So possibly a relatively complicated HDQUERY might be able to exec this stroed procedure with the right values?

John Golembiewski
Midwest Practice Principal
ITS Partners
Jgo@itsdelivers

John Golembiewski
Midwest Practice Principal
ITS Partners
Jgo@itsdelivers

bricast's picture

Relatively Complicated

Yes I know that whe need an HDQUERY. I just don't know how to write it.

MBHarmon's picture

Alternate Suggestion

I might make an alternate suggestion to you.
Link the incident and make sure people know to check for attachments on the "Parent" incident. I'd be concerned you'd run out of disk space copying the attachments.
Not what you asked, but I'd still think it a viable solution.

- Matt

bricast's picture

Disk Space

No need to worry about disk space each ticket would point back to the same file so there would only be one on file that they all point to.