Reading Data from Microsoft Access Files

Hello everyone. I am trying to make a custom interface tool/client for a Microsoft Access database, and I need to be able to read information from a Microsoft Access file. Are there any libraries or other tools available to do this?

Thanks in advance!

1 Like

Do you have to read the data directly from a file in MS Access format? If not export the data as a CSV file and read that into Processing instead.

1 Like

Yes. Can I write full-blown Java scripts in Processing? I just found a Java library that supports reading and writing to Access files.

Not sure what you mean by ‘full-blown’.

Can you provide a link to the Java library you found please.

I mean, Processing is a dialect of Java, so can I get away with just writing normal Java code?

https://jackcess.sourceforge.io/

1 Like

If you got the complete “.jar” file, you can simply drag it into the PDE (Processing’s IDE). :file_folder:

I plan on exporting this project as an application so that my co-workers can use it to query and update the database. If I understand your proposition correctly, then I wouldn’t actually be dealing with a live database after dragging the “.jar” file to the IDE (besides, I want to preserve the MS Access file so that I can continue to modify it directly).

I was talking about Jackcess’ “.jar” file:
SourceForge.net/projects/jackcess/files/jackcess/3.0.1/jackcess-3.0.1.jar/download

1 Like

Thanks for the link to the Access library it looks good. Yes you can write full Java applications in Processing.

I have just one concern and that is related to sharing the data between multiple users.

Access can be used in two ways

  1. Single user - single file and that is supported by this library.

  2. Multiple user - shared database file. This requires the database to be on a server using JDBC/ODBC for the connectivity between application and database. The server will be running a thread to manage database requests.

If you want to use this library to share and update the data then you would need a single file to be passed between the users, you can’t have multiple files because the data would become inconsistant due to lack of synchronization.

1 Like

Thanks for the information!

There is only one file that will be accessed by multiple users since the file is on a shared drive at our company. And it is a small group. It’s unlikely two people would want to access the database at the same time (it’s for freezer inventory, and there is usually only one person retrieving something from the freezer at a time). I mainly want to use this library to display information and make small edits.

There may be an option in the library to check the files status e.g. open (in use) ro cloased (available for us) or something similar. You could use this to prvent multiple user access.

1 Like