+ Reply to Thread
Results 1 to 6 of 6

Need help converting date/time from csv presented as "December 21st 2020 6:03 am", etc.

  1. #1
    Registered User
    Join Date
    02-10-2021
    Location
    Seattle, WA
    MS-Off Ver
    Office 365
    Posts
    4

    Need help converting date/time from csv presented as "December 21st 2020 6:03 am", etc.

    Hello,

    First post so bare with...

    I was given a csv file with date/time presented as "December 21st 2020 6:03:00 am", etc. I can't figure out how to convert to a format Excel recognizes for pivot tables and such. All months and days are in the file, along with times in am and pm.

    Does anyone know what I need to do here. Thanks in advance for your help!

    Michael
    Attached Files Attached Files
    Last edited by Locomikey5150; 02-10-2021 at 07:38 PM. Reason: Adding sample data

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2405 Win 11 Home 64 Bit
    Posts
    23,945

    Re: Need help converting date/time from csv presented as "December 21st 2020 6:03 am", etc

    Please read the yellow banner at the top of this page on how to attach a file.
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Registered User
    Join Date
    02-10-2021
    Location
    Seattle, WA
    MS-Off Ver
    Office 365
    Posts
    4

    Re: Need help converting date/time from csv presented as "December 21st 2020 6:03 am", etc

    If this is a duplicate reply, my apologies (still learning). File is now attached, and thank you.

    Michael

  4. #4
    Forum Contributor
    Join Date
    08-26-2016
    Location
    UK
    MS-Off Ver
    O365
    Posts
    260

    Re: Need help converting date/time from csv presented as "December 21st 2020 6:03 am", etc

    There's those pesky sts after 21; I imagine there are some nds and rds and ths too.
    If you remove those first with find & replace, then you'll be able to do a Text-to-Columns, splitting the date/times at the end of the date part, and choosing Dates:DMY for the first column and General for the second. Then you can add them back again into a single column of proper Excel Date/Time stamps.
    It would probably be safer to use Power Query to import directly from the csv files into Excel.

    Attach a sample csv file (preferably not an Excel file saved as a csv)

    Incidentally, what do those date and time stamps look like when there is only one digit for the day of the month?

  5. #5
    Registered User
    Join Date
    02-10-2021
    Location
    Seattle, WA
    MS-Off Ver
    Office 365
    Posts
    4

    Re: Need help converting date/time from csv presented as "December 21st 2020 6:03 am", etc

    Thanks, I'll give that a whirl. About to head out for a bit, but will give it a shot and report back once complete. Really appreciate the assist!

  6. #6
    Registered User
    Join Date
    02-10-2021
    Location
    Seattle, WA
    MS-Off Ver
    Office 365
    Posts
    4

    Re: Need help converting date/time from csv presented as "December 21st 2020 6:03 am", etc

    This did the trick, thank you! I really appreciate the assist.

+ 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: 12
    Last Post: 12-03-2020, 09:46 PM
  2. looking for a formula to change full date "01/08/2020" to "8"
    By danezeq in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-19-2020, 11:00 AM
  3. [SOLVED] Sorting Data Presented Monthly into Weekly "Buckets"
    By dflak in forum Tips and Tutorials
    Replies: 4
    Last Post: 10-26-2017, 12:11 PM
  4. [SOLVED] Converting "hh h mm m ss s" time format to "hh:mm:ss"
    By sohel.engr in forum Excel General
    Replies: 10
    Last Post: 09-28-2013, 03:15 PM
  5. Replies: 2
    Last Post: 11-01-2012, 04:35 PM
  6. [SOLVED] Excel 2007 : Converting "mm min ss s" time format to "hh:mm:ss"
    By blackmilk in forum Excel General
    Replies: 15
    Last Post: 04-23-2012, 04:14 PM
  7. Replies: 4
    Last Post: 07-14-2010, 03:17 PM

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