Consulting

Results 1 to 6 of 6

Thread: Export Excel Data into MySQL

  1. #1
    VBAX Tutor
    Joined
    Mar 2005
    Posts
    221
    Location

    Export Excel Data into MySQL

    Hello all.

    I have seen many applications that are able to export excel data into MySQL databases, and would like to construct one that will do the same.

    Currently, I have a main database in MySQL, which is also linked to Access.
    Do you think it would be easier to export to Access? If so, I may be in the wrong forum category.

    I have attempted to search for some code samples to get me started, but am unable to find any. Can anyone help get me started? Any help is appreciated, thanks.

  2. #2
    Once you have the drivers for ODBC for MySQL, exporting from Excel is as easy as using the export feature of Excel itself. It uses the same drivers. That's the best way to judge if it is any easier than Access. Exporting into Excel can only be done from tables, of course. Any of the features of a relational database will not be preserved.

  3. #3
    VBAX Tutor
    Joined
    Mar 2005
    Posts
    221
    Location
    hmm .. I am able to easily import SQL info, but I cannot find where in Excel to choose to export data? Is there somewhere in the menu to do this? I do have the driver set up.

  4. #4
    Moderator VBAX Guru Ken Puls's Avatar
    Joined
    Aug 2004
    Location
    Nanaimo, BC, Canada
    Posts
    4,001
    Location
    Hi there,

    I use ADO to send Export A Range Of Excel Data To A Database. The article in the link was built for Access, but there is a link to a full page of connection strings in the last line, so you should be able to easily change it to MySQL.


    Don't know if it's exactly what you're after, but thought I'd throw it out there anyway.
    Ken Puls, CMA - Microsoft MVP (Excel)
    I hate it when my computer does what I tell it to, and not what I want it to.

    Learn how to use our KB tags! -||- Ken's Excel Website -||- Ken's Excel Forums -||- My Blog -||- Excel Training Calendar

    This is a shameless plug for my new book "RibbonX - Customizing the Office 2007 Ribbon". Find out more about it here!

    Help keep VBAX clean! Use the 'Thread Tools' menu to mark your own threads solved!





  5. #5
    VBAX Tutor
    Joined
    Mar 2005
    Posts
    221
    Location
    Definately a good start. Thank-you. I will review this material and let you know my outcome.

  6. #6
    Quote Originally Posted by debauch
    hmm .. I am able to easily import SQL info, but I cannot find where in Excel to choose to export data? Is there somewhere in the menu to do this? I do have the driver set up.
    Actually, I was thinking of importing rather than exporting. But, try the "Save As" function and there are delimited files as an optional file type and you may be able import the delimited file into MySQL where this is a pretty typical procedure, "LOAD DATA INFILE ... FIELDS TERMINATED BY ..."

    Sorry 'bout that.

Posting Permissions

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