none
Is there a way to import dates with AM / PM Values from CSV using Access 2007? RRS feed

  • Question

  • Below is a simple text file example with 2 fields to import delimited by a comma. The first is a date and time value and the second is a city:

    07/25/2016 02:39:00 PM,Covina
    07/23/2016 03:39:00 PM,Rowland

    07/22/2016 01:39:00 AM,Walnut

    I get an error with the above date formats in the text file.  If I remove the am/pm values and use military time values it works but I would prefer the am/pm values for easier readability when viewing the text file.  Is there a way to import date/time values with the am/pm values into Access 2007? Thanks in advance

    Monday, July 25, 2016 10:12 PM

Answers

  • Hi zonkerman,

    form the description of the thread I assume you trying to perform this operation using user interface.

    so here I suggest you a solution for user interface. if you are not using user interface and using codding then please let me know so that I can suggest you a solution by codding.

    First I stored the data you had mentioned above in the Excel file and save it in .CSV Format.

    then I open Access Database.

    Go to "External Data" Tab. in that you will find Group "import & link". in that you will find an option written as "Excel" (Import Excel Spreadsheet).

    click on that , in the file name select the path to the .CSV File.

    Select the other option according to your requirement.

    at the end , when you finish all the steps you will see the data with AM /PM Format like below.

    Hope this steps will help you to solve your issue. if you still have a problem with that then let us know so that we can try to provide you further suggestion.

    Regards

    Deepak


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Tuesday, July 26, 2016 2:41 AM
    Moderator