Skip to main content

Hi  

 

My users wants 3 numbers to be within a cell in their download. 

The numbers are separated by a new line and are stored as 3 separate measure fields. 

 

For example,  

 

123  (from field 1) 

456  (from field 2) 

789  (from field 3) 

 

To achieve that I did something like this 

 

str([Field1]) + "  

  " + str([Field2]) + " 

  " + str([Field3]) 

 

It looks all good on the front end but when user downloads it to csv some of cells becomes a formula in the download and the numbers are not showing up correctly.  

 

I searched online and the AI suggested putting a prefix ' in the formula but it looks bad on the front end. 

 

Anyway around this without impacting the front end  ? 

 

Thank you 

 

 

 

#Tableau Desktop & Web Authoring

2 answers
  1. Aug 17, 2:28 PM

    @Amos Wang

     

    I just tested something out. Your method of getting those carriage returns is correct. I did an example in Tableau Prep to force the carriage returns into the output, of which the output is then used in Desktop:

    I just tested something out. Your method of getting those carriage returns is correct.Which then displays as much in Destop when using that output:Screenshot 2026-08-17 at 7.26.16 AM.png

     

    I then exported that out to .csv in Excel, and while the numbers are all retained in the single cell, the carriage returns are lost. 

    Screenshot 2026-08-17 at 7.27.54 AM.png

     

    I don't think this is as much of a Tableau issue as it is MS-Excel.  There may be some workarounds but it'll likely be on the end-user side.  E.g.,

    https://stackoverflow.com/questions/55290638/csv-carriage-return-dont-show-up-in-excel

     

     

    If this response answered your question, please mark it as an Accepted Answer? 

    This way, others searching for similar solutions will find the answer faster in the future.

     

    Best, Don Wise (Tableau Ambassador)

0/9000