Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Best way to extract data from a FileMaker Pro database in a script?

My job would be easier, or at least less tedious if I could come up with an automated way (preferably in a Python script) to extract useful information from a FileMaker Pro database. I am working on Linux machine and the FileMaker database is on the same LAN running on an OS X machine. I can log into the webby interface from my machine.

I'm quite handy with SQL, and if somebody could point me to some FileMaker plug-in that could give me SQL access to the data within FileMaker, I would be pleased as punch. Everything I've found only goes the other way: Having FileMaker get data from SQL sources. Not useful.

It's not my first choice, but I'd use Perl instead of Python if there was a Perl-y solution at hand.

Note: XML/XSLT services (as suggested by some folks) are only available on FM Server, not FM Pro. Otherwise, that would probably be the best solution. ODBC is turning out to be extremely difficult to even get working. There is absolutely zero feedback from FM when you set it up so you have to dig through /var/log/system.log and parse obscure error messages.

Conclusion: I got it working by running a python script locally on the machine that queries the FM database through the ODBC connections. The script is actually a TCPServer that accepts socket connections from other systems on the LAN, runs the queries, and returns the data through the socket connection. I had to do this to bypass the fact that FM Pro only accepts ODBC connections locally (FM server is required for external connections).

like image 630
postfuturist Avatar asked Aug 26 '08 17:08

postfuturist


People also ask

What is FileMaker scripting?

What is FileMaker Pro scripting? It can be defined as automation, a macro and even a programming language. FileMaker Pro scripting has elements of all these definitions. The original purpose of scripting was to automate the mundane task of printing a report.


1 Answers

It has been a really long time since I did anything with FileMaker Pro, but I know that it does have capabilities for an ODBC (and JDBC) connection to be made to it (however, I don't know how, or if, that translates to the linux/perl/python world though).

This article shows how to share/expose your FileMaker data via ODBC & JDBC:
Sharing FileMaker Pro data via ODBC or JDBC

From there, if you're able to create an ODBC/JDBC connection you could query out data as needed.

like image 58
Ryan Farley Avatar answered Sep 28 '22 08:09

Ryan Farley