how to intelligently parse .qif files

matthew wilson waxmop@linuxfreemail.com
Fri, 14 Dec 2001 07:30:05 -0800


I've been using GnuCash for several weeks now.  I downloaded a .qif file from my bank and imported the data, assigning everything to 
the Expenses:Everything category.  Then I went through my Assets:Checking account and reassigned each of the items in my checking 
account to the appropriate account.  For example, every Starbucks expense went to the Expenses:Fun:CoffeeShops account.

I'm really happy that GnuCash allows me to create these nested expense account classifications, but I'm not looking forward to 
reassigning each line-item next month with my next statements.

I thought about writing a few perl scripts to read and rewrite the .qif files I download that would classify my expenses for me.  For example, 
all lines that contain the string "office depot" would get flagged as "Expenses:Home computer and office".

Before I get started on that, has anyone else tried something like this?  Is there already this functionality built in and I just don't know about 
it?

Here's another question.  If I'm gonna parse a .qif file, is it necessary/ideal to write the results back into a .qif format, or should I dump into 
XML?  I opened a few .qif files in emacs, and they look pretty goofy.


Thanks for the help.

Get your own FREE E-mail address at http://www.linuxfreemail.com
Linux FREE Mail is 100% FREE, 100% Linux, 100% better, and 100% yours!