2 Replies Latest reply on Apr 5, 2016 10:53 AM by Taylor Hintz

    Correct Time Format from Excel to Tableau

    Taylor Hintz

      I have a project connected to an Excel spreadsheet with one of the columns as time, in a hh:mm:ss format. There's also a separate Date column formatted as mm/dd/yy. Tableau had no problems with my date data, but not only does it add a date of 12/30/99 to my time field, it also doesn't create the right times. Is there some other format I need to use?


      I notice there is no "Time" data type, just a "Date/Time" type; however, I would like to keep separate fields of date and time for how I would like to visualize the data, i.e. creating a page shelf or filter that only affects the time field. I'm not sure if there's a way to do that still with date and time being added as a single and not separate dimensions.

        • 1. Re: Correct Time Format from Excel to Tableau
          Sharad Joshi

          Hi Taylor,

          You can change the default data type of your time column from date-time to string while connecting to the source on " Connect tot Data Source Page" .

          This will ensure that a default date is not appended in front of your time data.

          Have a look at the screenshot ( Change from Date & time to String ).


          1 of 1 people found this helpful
          • 2. Re: Correct Time Format from Excel to Tableau
            Taylor Hintz

            Thanks Sharad. I was able to eliminate the date by turning it into a

            string; however, as a string, Tableau also sorts the data in a mixed order

            as it is not grouping the AM's and PM's together. Here's what the sort

            order looks like:


            I would like to keep it as an AM/PM for user friendliness, but I don't see

            a way to sort the data unless I have to do so manually (There are 1,300

            different time records, about as many different minutes as there are in a

            day). And I need to sort the time this way to show variations in the number

            of records throughout the day. Do you know how I can get this sorted?


            On Mon, Apr 4, 2016 at 11:59 PM, Sharad Joshi <tableaucommunity@tableau.com>