4 Replies Latest reply on Jul 10, 2018 1:09 AM by Donna Coles

    Exporting CSV file from underlying data


      Hi All,


      When i am exporting .csv file from underlying data, i am getting alphabetical order instead of my customized arrangements in text table.


      how can i achieve this scenario in tableau;




      in text table i have columns like:::  Person ID, Person Name, Person PIN, Account Number, Balance, Avg Balance  per Month, Customer Usage, Max Billing date, Billing Address.


      when i am exporting into CSV File::: Account Number, Avg Balance per month, Balance, Billing Address, Customer Usage,Max Billing date,Person ID, Person Name, Person PIN.


      but user want to see as mentioned in text table.


      Please let me know if you need more details to address this issue.


      Thank you

        • 1. Re: Exporting CSV file from underlying data
          Jeff Strauss

          This is the way that export to CSV works.  You can also try crosstab to see if this helps.  What I ended up doing as a workaround is to prefix the headers with a number such as:


          1_company_id, 2_project_name, 3_person_name

          • 2. Re: Exporting CSV file from underlying data

            Hi Jeff,


            Thank you for response, but i am not expecting this way,


            is there any other way to show the expected results.


            Thank you

            • 3. Re: Exporting CSV file from underlying data
              Deepak Rai

              Go to Worksheet Menu>Copy>Crosstab and Paste in Excel


              Exported .csv would always default to alphabetic view



              • 4. Re: Exporting CSV file from underlying data
                Donna Coles

                Hi Amyl


                As Jeff says, if you're on server, then whether you choose to  View Underlying Data  via a tooltip option or Click Download ->Data from the server menu toolbar, you will get the View Data pane displayed like below, which will always show all the columns in you primary data source in alphabetical order



                This is expected behaviour, but there are plenty of people who would like more control over how the 'view underlying data' option displays - feel free to vote up this idea https://community.tableau.com/ideas/1123


                In the meatime, if you have a requirement to provide an 'export to excel' option of an ordered list of specific columns then you will need to

                a) create a view that shows the data you want in the right order

                b) put the view on a dashboard

                c) instruct a user to select Download ->Crosstab from the Server menu instead as this will show the list exactly as you've defined

                If the Crosstab option is greyed out, it's likely because none of the views on the dashboard 'have focus', so server doesn't know what data you want to export to crosstab.  This can be resolved by clicking on a cell/header in the relevant view and then downloa3d ->crosstab.  However, this can be a little fiddly to explain to users


                If you don't actually want to show the table of data as you want to show a graphical view of the data, but allow the user to 'export the underlying' data in a specific tabular view, then you can do the above, but 'hide' the view you want to export, and provide a button to do the export instead.  See how to do this using Andy Kriebel's blog here The Greatest Tableau Tip EVER: Exporting CSV made simple!


                Hope this helps



                1 of 1 people found this helpful