To convert American Express CSV to QIF

Wes Metz wes704 at gmail.com
Wed Jan 21 12:08:14 EST 2015


Michael, I download AMEX transactions as MSEXCEL and use XL2QIF to convert
them for importing to GNUCash. There is also CALC2QIF.



On Mon, Oct 27, 2014 at 4:38 PM, Michael DeBusk <mdebusk at gmail.com> wrote:

> Some time back, I found that I could no longer download QIF files from
> American Express. I could, however, get a CSV. The following is my
> first shot at a one-liner to convert that particular CSV to QIF.
>
> cat ofx.csv | sed -e 's/\"//g;s/Reference\:\ //g;s/ \{1,\}/ /g'
> ofx.csv | awk -F, '{ print "D" $1; print "N" $2; print "T" $3; print
> "P" $4; print "M" $5; print "LExpenses:&&"; print "^"; }' > amex.qif
>
> It's not perfect, but since I can barely scratch the surface of awk
> and sed, it'll do. I haven't found that it ruins anything. If anyone
> can improve upon it, I'd be grateful.
>
> (The last awk instruction to print "LExpenses:&&" creates an account
> placeholder for me in each transaction. I go in and edit the QIF
> afterward, replacing "&&" with the appropriate account name.)
>
> --
> ()  ascii ribbon campaign     * against html e-mail
> /\  www.asciiribbon.org       * against proprietary attachments
> Home: http://nlphilia.com     * Blog: http://nlphilia.net
> Registered Linux User #450983 * Ubuntu Counter Project #10548
> _______________________________________________
> gnucash-user mailing list
> gnucash-user at gnucash.org
> https://lists.gnucash.org/mailman/listinfo/gnucash-user
> -----
> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.
>


More information about the gnucash-user mailing list