How can I display in email query certain column of selected row in a table?

  • Goal: I have a table with some values that the user can select, then then with a button it should trigger an email that sent certain column of the selected rows.

  • Details: In the email query i tried to use this but I am not sure is the correct syntaxt? {{table1.selectedRow?''}}
    Maybe I need to write a Javascript query to loop through all the selected row first?

You're almost there - the selectedRows (or selectedRow if you only allow single selection) is the table property you want to access. If the data you need isn't displayed in the table (often a primary key etc) then you'll want to access the selectedSourceRow(s) option instead.
eg the array of email addresses of the selected rows in the table are extracted and joined together here with line breaks to display in the text area:


Thank you for your help. When I try to do that I get this error. What I am doing wrong?

Sorry, was just a mistake in referencing the wrong table.

Now works, with an text base component, but if I use it in the email query it gives null in the actual email. Any suggestion?

1 Like

Hi there,

Thanks for reaching out to us! I was able to reproduce this issue.

Just for my clarification, does removing the ('\n')after the join successfully shows the text?


The main problem was that it would try to run the email query before it actually got the data.

So I first, trigger the JavaScript query to compile the URLs and then once successful, trigger the email query.

So creating a separate Javascript for this and then run this logic in the button solved the problem.

Regarding the /n was still not working but it required html so with br worked.

1 Like