Tutorial :Export mysql database to Microsoft Access (.mdb)



Question:

I'm looking for some tips on how to export a mysql database into a .mdb file that is readable by Microsoft Access 2007+ (and editable too!). It needs to be a script that can run on a Linux server (maybe using PHP?).

I can't seem to find out anything anywhere. Any ideas?

Cheers!


Solution:1

Thanks for your tips :)

I have since found out we're already using this product elsewhere: http://dbconvert.com/convert-access-to-mysql-pro.php?DB=1 It's running under Wine on our server, although I don't think it supports the latest versions of Access.


Solution:2

  1. Install the ODBC driver from MySQL.
  2. Create the ODBC system DSN entry.
  3. On Access, execute a query like this:

SELECT * INTO AccessTable FROM [ODBC;DATABASE=Database_Name;DSN=DSN_Name;OPTION=2059;PWD=MySQL_Password;PORT=0;UID=MySQL_User].MySQLTable

(Replace accordingly: AccessTable, MySQLTable, Database_Name, DSN_Name, MySQL_Password, MySQL_User)


Solution:3

You could create a a CSV file from MySql and then import that into Access. You can use OLEDB or ODBC connection to access and should be able to do the inserts that way.

Are you also trying to create the mdb file on the fly? I'm assuming that you have one built already and just want to export the data from mysql and import into access.


Solution:4

I have not tried this.

The unixODBC Project goals are to develop and promote unixODBC to be the definitive standard for ODBC on non MS Windows platforms. This is to include GUI support for both KDE and GNOME.

-- http://www.unixodbc.org/


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »