Backup idea

Jean-David Beyer jdbeyer at exit109.com
Tue Jul 20 14:48:52 EDT 2004


Alan H. Lake wrote:
> I have received a request and have an idea as to how to fulfill it.
> I'd like to know if someone has a better idea or has developed part of
> what the implementation of this idea would require.
> 
> The request is to be able to back up the GnuCash data so that it could
>  be read by Excel.  The thinking is that Linux machine are still in the
>  minority and it would be good to be able to get at the data on a
> Windows machine in case of a disaster.
> 
> It appears that GnuCash stores its data in XML format.  I could use PHP
>  to access the data, then write it out in CSV format.  Right now, I
> don't know all of the tags that I might encounter, but I do know which
> ones are being used in the file I need to back up.
> 
> Are there any ideas or suggestions that might expedite this project?
> 
My only interest in this is very slight. If it were written out as a bunch 
of tables, each defined in a suitable DML, then I could enter them into a 
relational database management system. But any dbms that handles SQL 
should do just fine and it is my understanding that you can do that with a 
suitable version of GnuCash. So why not just run that version of GnuCash 
and use postgreSQL (or whatever one it is that GnuCash can use) and use 
that to export the tables as either CSV or TSV format.

I strongly suggest using TSV instead of CSV because fields may contain 
commas. I know some of mine do. I never looked at the XML to see what it 
did with commas.

-- 
   .~.  Jean-David Beyer           Registered Linux User 85642.
   /V\                             Registered Machine   241939.
  /( )\ Shrewsbury, New Jersey     http://counter.li.org
  ^^-^^ 14:45:00 up 4 days, 26 min, 4 users, load average: 4.45, 4.16, 4.09



More information about the gnucash-user mailing list