+ Reply to Thread
Results 1 to 6 of 6

Best approach to presenting date/time formatted data

Hybrid View

  1. #1
    Registered User
    Join Date
    02-11-2012
    Location
    London, England
    MS-Off Ver
    2021
    Posts
    41

    Best approach to presenting date/time formatted data

    I have a few columns with text in ISO8601 format such as 2016-04-30T06:48:52. Does a facility in Excel exist where the text can remain in the format but the column display as custom date/time and allow sorting?

    Thanks!

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,065

    Re: Best approach to presenting date/time formatted data

    Since the format is

    YYYY-MM-DDTOHH:MM:SS

    you can simply sort on the data as it is.
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2404
    Posts
    24,784

    Re: Best approach to presenting date/time formatted data

    If this data is text, you can't display that data any other way in place. You can create a new column that uses a formula like this to convert to date/time:

    Formula: copy to clipboard
    =DATE(MID(A1,1,4),MID(A1,6,2),MID(A1,9,2))+TIME(MID(A1,12,2),MID(A1,15,2),MID(A1,18,2))


    and then format it however you want.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  4. #4
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS 365 Family 64-bit 2404
    Posts
    24,784

    Re: Best approach to presenting date/time formatted data

    Special-K makes a great point. If all you care about is sorting, the original data is sortable since most significant values appear from the left.

  5. #5
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2021
    Posts
    5,960

    Re: Best approach to presenting date/time formatted data

    Try this ...

    =--SUBSTITUTE(A1,"T"," ")

    Or ...

    =--REPLACE(A1,11,1," ")

  6. #6
    Registered User
    Join Date
    02-11-2012
    Location
    London, England
    MS-Off Ver
    2021
    Posts
    41

    Re: Best approach to presenting date/time formatted data

    Ok, all those suggestions help a lot. Is it possible to devise a format string that hides the "T" much like the formula above, but without creating a new column or formula?

    Thanks a lot everyone!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 2
    Last Post: 06-26-2014, 08:59 AM
  2. [SOLVED] UDF MLOOKUP takes too much time. Alternative approach needed.
    By radionut in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 08-16-2013, 05:58 PM
  3. [SOLVED] Help for v-lookup approach instead of manually cell linking approach - Excel 2010
    By Mirisage in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 05-31-2013, 01:32 PM
  4. A more structured approach to programming - only for those with a bit of time!
    By twills in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-27-2009, 09:13 AM
  5. Replies: 11
    Last Post: 08-10-2009, 03:38 PM
  6. Adding time to date-time formatted cell
    By tawtrey(remove this )@pacificfoods.com in forum Excel General
    Replies: 4
    Last Post: 08-12-2005, 06:05 PM
  7. Subtracting Cells formatted with Date AND Time to get hours?
    By mcr1 - ExcelForums.com in forum Excel General
    Replies: 1
    Last Post: 07-05-2005, 05:05 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1