Home

Macro

Paths

Insert Data

Example 1

Example 2

Blog



Evaluation of GnuCash Data in OpenOffice.org



Important notice: This macro will be outdated with the release of GnuCash 2.4, as it will then be possible to save your GnuCash data directly into one of the common SQL-databases. Ooo-base can then be used as frontend on that database. See www.gnucash.org for further information.



Monatliche Ausgaben meines reichen Onkels

Fig1: Monthly expenses of my rich uncle... ; -)

In GnuCash.org's FAQ it is said:

Q: "Can you please add a password feature?"
A: The core developers – which includes those with long-term experience with well-known names/brands in computer security – believe that each app should do one thing well, and leave other concerns to other apps. Especially "tricky", critical concerns like data security. In this case, GnuCash would do a poor job of being a good security application.

That must be true for reporting also. Indeed, why should GnuCash deal again with Pivot-tables and bardiagrams, when there is an excellent Open-Source-application - OpenOffice.org - that does just that?

The data from GnuCash must be available in Openoffice.org, though. In the future it may become possible to save the output of GnuCash into a SQL-database directly, but until then we will have to transform the present XML-file periodically and insert the data into the database ourselves. As I could not find anything appropiate for this purpose on the web I have written an OpenOffice.org-macro that imports GnuCash's data into OpenOffice.org Base and that I hereby present to the general public.

Once the data are imported they can be evaluated in Base or Calc to your heart's content.

Limitations and Preconditions

Multiple currencies are not supported, only account data are imported, i.e. no schedules and no budgets for example. I have not tested if and how far it works with business accounts.

Unfortunately, some users, from my experience notably Windows XP and Vista users can only process uncompressed GnuCash files due to limitations of the python version that has been embedded into OpenOffice.org 2. This means that some of these users will have to unzip their GnuCash file or store it as an uncompressed xml-file out of Gnucash (see Edit-Menu -> Preferences -> General, deselect "Compress files"), if they want to apply the macro. Just try.

If you are a Linux-user, please check that Sun's Java Runtime Environment is activated under Tools -> Options -> OpenOffice.org -> Java. If it is not offered for activation you will have to import e.g. package sun-java6-jre from the multiverse repository, if you use (k)ubuntu. Please refer to your distribution's support, this is a much discussed topic, seems to be a license problem as sun does not offer its (more functional) java compiler under GPL. This is how it must look like.

Procedure

Below I shall present,

There is a blog, where you can leave comments, report bugs, etc.

Alternative "products"

Similar solutions can be found at:
http://www.xaprb.com/blog/2006/03/12/gnucash-to-mysql-export-script/ and
http://blog.edseek.com/archives/2005/08/18/gnucash-export-to-gnumeric-and-csv/



First step: download macro





imprint/contact