I've got a problem of obtaining access to .mdb file (MS-Access db) on Ubuntu. I need full access(read and write too).
Originally project was built on Windows using odbc (and everything has worked well). But when I moved it on linux-server appeared problems.
At the moment PHP-extensions for work with odbc are installed. But I can't find any free ODBC-driver for work with Access. I've tried to use MDB Tools but seems it works only for reading.
Maybe somebody can suggest any solution? Usage of some another DB is not appropriate, because my boss is against it.
Thanks for any help.

- 196
- 2
- 9
-
What was the reason you moved it to Linux? – Burhan Khalid Feb 15 '12 at 10:11
-
We just going to abandon usage of Windows on our servers – RaskolnikOFF Feb 15 '12 at 10:13
-
1"We just going to abandon usage of Windows on our servers" It's obligatory you change the DB technology if you're going to abandon Windows on the servers. No other solution, I'm afraid. EDIT: Unless you run a Windows Virtual Machine inside Ubuntu ;-) Gosh, how ugly and useless that would be. – Flukey Feb 15 '12 at 10:16
-
I see that question as well as situation in general are ridiculous, but it's not my decision. – RaskolnikOFF Feb 15 '12 at 10:23
-
3You need to tell your boss that this isn't going to work. Really. It's ludicrous. – Flukey Feb 15 '12 at 10:30
-
Have you seen http://www.easysoft.com/products/data_access/ ? Also there are a few post on SO [linux] [ms-access]. However, I agree that telling your boss that this is not sensible is the best solution. – Fionnuala Feb 15 '12 at 11:25
-
Easysoft drivers aren't free as far I understand. – RaskolnikOFF Feb 15 '12 at 12:05
5 Answers
By installing mdbtools from the Linux repository you can work with mdb in Linux. mdbtools is a free package that can solve your problem.
Take a look at this tutorial

- 9,551
- 1
- 25
- 36

- 171
- 2
- 11
You can read/write MS Access files using ADODB, the PHP libraries for ADODB can be found here: http://adodb.sourceforge.net/

- 4,933
- 3
- 20
- 32
-
2It doesn't support access on linux too as you can see here http://phplens.com/adodb/supported.databases.html – RaskolnikOFF Feb 15 '12 at 14:35
-
@RaskolnikOFF Ah apologies, missed that, I suppose you will have to follow a solution using WINE to mount a virtual windows machine and connect via that. – Matt Donnan Feb 15 '12 at 16:41
Thanks everybody for your help. Finally we decided to use another DB. My answer on this question - it's impossible(if you need to write to DB) to use Access DB on linux based only on free solutions. If you need only read you can use MDB tools with PDO. If you're ready to pay you can try EasySoft solutions.

- 196
- 2
- 9
-
1Well even only reading with the most simple query is giving me problems using mdbtools on Ubuntu v14 64bit. It gives me segmentation faults. – Jan Dec 15 '16 at 15:32
I've just used RebaseData
apt-get install curl libreoffice-calc
curl -F files[]=@example.mdb https://www.rebasedata.com/api/v1/convert?outputFormat=csv -o output.zip

- 714
- 1
- 8
- 24
You can link the access database to a free SQLServer Express Edition. Then you can insert or select data from any access table using freetds and unixodbc from your linux box. Yes, you need a windows box in your network with the access file and the SQLExpress service. Any database with windows support (DBF, XLS, etc.) can be used this way.

- 1