+ Reply to Thread
Results 1 to 6 of 6

Convert String to Date in Column

  1. #1
    Forum Contributor
    Join Date
    03-03-2011
    Location
    Ottawa, Ontario
    MS-Off Ver
    365
    Posts
    136

    Convert String to Date in Column

    I have a column of dates from a MySQL database that are varchar. I need to be able to do a date range search on this column so I need to convert them to an excel date format but I haven't been able to find anything that really helps me. Right now the format is DD/MM/YYYY in Column C. I shouldn't have a problem doing the search, I just need a little help with getting them in the proper format. So to simplify my question: Convert a dd/mm/yyyy string to date ??

    Thanks for any help.

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Convert String to Date in Column

    Are you sure they are strings?
    If posting code please use code tags, see here.

  3. #3
    Forum Expert Jakobshavn's Avatar
    Join Date
    08-17-2012
    Location
    Lakehurst, NJ, USA
    MS-Off Ver
    Excel 2007
    Posts
    1,970

    Re: Convert String to Date in Column

    Give this a try:


    Please Login or Register  to view this content.
    Gary's Student

  4. #4
    Forum Contributor
    Join Date
    03-03-2011
    Location
    Ottawa, Ontario
    MS-Off Ver
    365
    Posts
    136

    Re: Convert String to Date in Column

    Not 100% sure they are strings (listed as varchar in the MySQL database) but they show up in the columns as 08/02/2012 etc. If I try to do a sort on this column I can only do 'A-Z' but using the function from Jakob (DaterCNV) I can sort 'Oldest to Newest' .

  5. #5
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: Convert String to Date in Column

    Well it sounds like they were strings.

    I just asked because I've imported dates from MySQL into Excel with no problem.

  6. #6
    Forum Contributor
    Join Date
    09-23-2008
    Location
    Mexico
    Posts
    200

    Re: Convert String to Date in Column


+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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