Home > Forum > General > Add atachment action

Add atachment action
0

Hello, is there possible to choose attachment version in add attachment action? I added action and this is working but always choose the newest version of attachment

MVP

Hi Robert,

I have stumbled about this information in the online help for the "add attachment" action when answering another question:
______
3) Attachment selection via SQL query can work in two ways:
.....
2. When attachments are to be created during the action’s execution, the query MUST return columns FileName and Content, containing the attachment’s name and byte content. The query may also return a Description column, when there is need for an attachment to also contain a description.

E.g.: SELECT convert(image,'0x') AS Content, 'file1.txt' AS FileName
____
Using the WFHistoryAttachments table this could work
https://developer.webcon.com/2021/resources/db/#WFHistoryAttachments

SELECT convert(WFA_Value,'0x') AS Content, WFA_Name AS FileName
from WFHistoryAttachments
where --Depends on your requirements

I currently have no time to check this out, but at least it could help you.

Best regards,
Daniel

Did you know that with WEBCON you can automate virtually any process? Even baking cookies 🍪
 
Speaking of cookies: we use the ones that are essential for our website to function properly, as well as additional ones that help us customize our content to your preferences. If you don’t mind cookies, click Accept. If you want to learn more, explore settings.
Settings