How to open an .accdb file in Ubuntu?

Viewed 31914

The development machine I work on has Ubuntu Jaunty Jackalope as its operating system. I have been presented with data for a project I'm working on in the form of an .accdb file created by Microsoft Access. I do not own a copy of Microsoft Access. I do have Open Office installed and would be willing to install any software package available to my operating system. Is there a way I can open or transform this file so that I can view and edit the data on my computer? Is there another format that the Access database could be saved as that I would be able to open?

9 Answers

A good format to view and work with on Linux would be CSV.

As the accepted answer suggests MDB Tools does the job. To export all the tables on Linux to CSV format try this command:

mdb-tables -d ',' database.accdb| xargs -L1 -d',' -I{} bash -c 'mdb-export database.accdb "$1" >"$1".csv' -- {}

You can use mdbtools also into windows via WSL (Ubuntu on Windows or Debian on Windows): Then install it in console with:

sudo apt install mdbtools

I found this blog: http://tahsinabrar.com/open-a-microsoft-access-accdb-file-in-ubuntu/ In case the link is broken, the contents say:

We can use the UCanAccess JDBC driver to connect to Access databases (.mdb and .accdb) in LibreOffice Base. Here’s how I did it on a clean install of Ubuntu 14.04 LTS.

First, I installed LibreOffice Base itself

sudo apt-get install libreoffice-base

Then I downloaded UCanAccess to my Downloads folder and unzipped it.

I launched LibreOffice (not Base, just LibreOffice itself)

LibreOffice.png

and chose Tools > Options

On the Advanced tab I clicked the “Class Path…” button and then added the following five (5) JAR files using the “Add Archive…” button:

/home/abrar/Downloads/UCanAccess-2.0.9.5-bin/ucanaccess-2.0.9.5.jar /home/abrar/Downloads/UCanAccess-2.0.9.5-bin/lib/commons-lang-2.6.jar /home/abrar/Downloads/UCanAccess-2.0.9.5-bin/lib/commons-logging-1.1.1.jar /home/abrar/Downloads/UCanAccess-2.0.9.5-bin/lib/hsqldb.jar /home/abrar/Downloads/UCanAccess-2.0.9.5-bin/lib/jackcess-2.1.0.jar

Note that you must close and re-open LibreOffice for the new Class Path values to take effect.

Then I launched LibreOffice Base, and in Step 1 of the wizard I chose “Connect to an existing database (JDBC)”

The Access file I wanted to manipulate was named “baseTest.accdb” in my Downloads folder, so in Step 2 the “Datasource URL” was

jdbc:ucanaccess:///home/abrar/Downloads/baseTest.accdb

and the “JDBC driver class” was

net.ucanaccess.jdbc.UcanaccessDriver

In Step 3, I left the “User name” field empty and just clicked “Next

”.

In Step 4, I saved the LibreOffice Base database as “accdbTest.odb” in my Documents folder.

When the wizard completed it opened my LibreOffice database and I could see the tables in the .accdb file

But you have download and unzip UCANACCESS first from here: http://ucanaccess.sourceforge.net/site.html

I can see all the tables in LibreOffice Base. Here is one:

tableimg

Related