Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Concatenating Fields in Email Tool

Brett_A
5 - Atom

Hey guys, I am a newbie with Alteryx and I have a workflow where I am creating a concatenated field that I am trying to include in the middle of an email's body separated by newlines. It is a list of website links generated based on IDs. I am able to create individual hyperlinks using the concatenate tool, but they all appear on the same line in the body of the email.

 

I have seen solutions involving tables that I can't get to work as throwing the data into a table removes all of the formatting that I have created for the body of the email. In the examples I have seen, they WANT the table format as the body of the email, and that is NOT what I am looking for - I want a standard email body with a list of websites on new lines. 

 

Is there any way to have Concat_link concatenate properly in the middle of an email's body with newlines? Or am I perhaps misunderstanding how to use the table method?

 

The example I have attached will generate the 4 individual hyperlinks that work when placed in the body of the email, but the newline is not picked up by the email tool. The browse tool shows exactly what I am trying to achieve in the correct formatting.

 

Here are the solutions involving Tables:

 

community.alteryx.com/t5/Alteryx-Designer-Discussions/Working-with-wanted-line-breaks-and-the-Table-...

 

community.alteryx.com/t5/Alteryx-Designer-Knowledge-Base/Email-Tool-not-recognizing-newlines-in-conc...

4 REPLIES 4
JoaoLeiteV
10 - Fireball

Hello @Brett_A,

 

I came across this post that might help you out. If this doesn't work, there's also this one.

 

Let me know if they'll work out for you! I had the idea to add a "<br>" at the end of the concatenate link, as HTML reads it as a new line, but I don't know if that would work.

Brett_A
5 - Atom

Thanks for looking into this - both of those unfortunately have the same problem of wanting the format to stay as a table. The email tool recognizes the newlines when put through the table tool, but having the body of the email be a table wouldn't look great for what I'm trying to do.

 

I have tried <br> as well but the email tool ignores it.

patrick_digan
17 - Castor
17 - Castor

@Brett_A You should be able to use the regex_replace trick to replace the newline character with an html line break character <br />

REGEX_Replace([Body],"(\n)+","<br />")

Then it comes through as expected in an email when I tested it:

patrick_digan_0-1626283542099.png

Hope that helps!

Brett_A
5 - Atom

That worked perfectly, thank you! Guess I was too focused on the Table part of those solutions haha.

Labels
Top Solution Authors