Alteryx Designer Knowledge Base

Definitive answers from Designer experts.
There's still time to register for the Q3 ACE Panel - Spatial Edition presentation tomorrow! | Need more information about the event? Check out the post here

Email Tool not recognizing newlines in concatenated field

7 - Meteor
Created

Environment Details


  • Alteryx Server
    • All Versions
  • Email Tool


Cause


When New lines (\n) are inserted into a concatenated field to separate the values, the email tool cannot read theses values. Here we have summarize tool which concatenates values into a single field and uses a newline (\n) separator. When this is parsed through the email tool, the body does not recognize the line break which means the email will display a single line or paragraph.



Email Results



Resolution


Thankfully there have been many community posts providing solutions on how to overcome this issue (see community posts at the end of this article). For the purposes of this example i will use the regex replace function along with Table reporting tool. 

Step 1: Use a formula tool to replace \n with html break tags
REGEX_Replace([Concat_Value],"\n","
")
Step 2: Insert a Table tool from the Reporting palette
Step 3. Attach the formula tool to the Table tool
Replace([Table],"<br />","
")
Step 4: Finally attach the email tool which should produce the following results

Community post references:

Great post from Patrick. This article is based on his solution
https://community.alteryx.com/t5/Alteryx-Designer-Discussions/Working-with-wanted-line-breaks-and-th...

Alternative solution for inserting a new line using multiple fields
https://community.alteryx.com/t5/Alteryx-Designer-Discussions/Insert-a-carriage-return-for-a-new-lin...