{"id":633,"date":"2011-09-05T21:38:45","date_gmt":"2011-09-05T21:38:45","guid":{"rendered":"http:\/\/www.gssezisoft.com\/main\/?p=633"},"modified":"2013-06-25T03:38:50","modified_gmt":"2013-06-25T03:38:50","slug":"exporting-gnucash-data","status":"publish","type":"post","link":"http:\/\/www.gssezisoft.com\/main\/2011\/09\/exporting-gnucash-data\/","title":{"rendered":"Exporting GnuCash Data"},"content":{"rendered":"<p>It is easy to get information into GnuCash, but getting it out is a different matter. <!--more--><\/p>\n<h1>Background<\/h1>\n<p><a href=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file.jpg\"><img loading=\"lazy\" src=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file.jpg\" alt=\"\" title=\"gnucash-file\" width=\"175\" height=\"124\" class=\"alignleft size-full wp-image-634\" srcset=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file.jpg 350w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file-150x106.jpg 150w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file-300x212.jpg 300w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file-148x104.jpg 148w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file-31x21.jpg 31w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file-38x26.jpg 38w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-file-303x215.jpg 303w\" sizes=\"(max-width: 175px) 100vw, 175px\" \/><\/a>The version of GnuCash that I&#8217;m using at the moment (2.4.2) doesn&#8217;t have an option to export the data.<\/p>\n<p>It makes sense &#8211; a lot of programs these days are happy to import data from other programs they are replacing; but are reluctant to provide information for anything replacing it. Still, it&#8217;s not really a very &#8220;Open Source&#8221; attitude.<\/p>\n<p>It is really just a minor annoyance because GnuCash is Open Source and they&#8217;ve done a lot of good things which does make exporting possible. One example is the use of XML for the data so, * in theory *, you can get the information into anything else in any format imaginable. In practice, it is a little harder.<\/p>\n<h1>The Easiest Way<\/h1>\n<p>It really was very very simple to Export. You just pick Reports, Transaction Report, Select All Accounts, Sort by Date, include the things you need, and don&#8217;t do any totalling.<br \/>\nYou got a nice report listing everything.<\/p>\n<p>Then you click the top left and drag to the bottom right of the report, copy, and paste wherever you want (Excel worked great).<\/p>\n<p>The only slight inconvenience was the report was fairly long and you had to drag for some time (Ctrl-A = Select All, would have been nice).<\/p>\n<p>Unfortunately, when I upgraded to 2.4.2 I could no longer select All Accounts. Maybe it is a feature. Maybe it&#8217;s a bug that is being fixed.<\/p>\n<h1>The Workaround<\/h1>\n<p>You can still make it work if you select Assets and Liabilities, export that, select Income and Expenses, and export those.<br \/>\nIt is a bit harder, and you do end up with duplicates that aren&#8217;t totally obvious, but it does work and it is easier than any other option I&#8217;ve tried.<\/p>\n<p>The report settings I use are:<br \/>\n<a href=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display.jpg\"><img loading=\"lazy\" src=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display.jpg\" alt=\"\" title=\"gnucash-report-options-display\" width=\"212\" height=\"317\" class=\"alignleft size-full wp-image-635\" srcset=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display.jpg 424w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display-100x150.jpg 100w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display-200x300.jpg 200w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display-98x148.jpg 98w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display-20x31.jpg 20w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display-25x38.jpg 25w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-display-143x215.jpg 143w\" sizes=\"(max-width: 212px) 100vw, 212px\" \/><\/a><a href=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting.jpg\"><img loading=\"lazy\" src=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting.jpg\" alt=\"\" title=\"gnucash-report-options-sorting\" width=\"212\" height=\"317\" class=\"alignleft size-full wp-image-636\" srcset=\"http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting.jpg 424w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting-100x150.jpg 100w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting-200x300.jpg 200w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting-98x148.jpg 98w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting-20x31.jpg 20w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting-25x38.jpg 25w, http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/gnucash-report-options-sorting-143x215.jpg 143w\" sizes=\"(max-width: 212px) 100vw, 212px\" \/><\/a><\/p>\n<div style=\"align:none\">&nbsp;<\/div>\n<h1>To QIF<\/h1>\n<p>There is a great little tool that will take a GnuCash data file and create a QIF file from it. This is neat because we usually get data in from a QIF file. Going back to QIF makes it a symmetric process &#8211; you can get back what went in.<\/p>\n<p>The other neat thing is the author wrote it in Java so it should run under any Operating System.<\/p>\n<p>You do need to un-ZIP the gnucash data file but that is easily done. On Windows I use 7Zip but you could just as easily use WinZip or Windows&#8217; built in tool. With earlier versions of GnuCash you had to fix the XML header but that has already been fixed in 2.4.2<\/p>\n<p>The program is <a href=\"http:\/\/gnucashtoqif.sourceforge.net\/\">GnuCashToQIF<\/a>.<\/p>\n<p>It simply asks for the XML file to convert and where to put the QIF.<\/p>\n<p>You can open the QIF file in Notepad, copy the content, and paste it into Sheet1 of the following Excel spreadsheet. It has a macro which will read the raw QIF information and make a transaction list in Sheet2. Use Alt-F8 QIFtoSheet to run the macro.<br \/>\nNOTE: Excel loses &#8220;$&#8221; at the start of split lines in the QIF so this doesn&#8217;t work well if you have a lot of splits.<br \/>\nAlso, the Java program outputs unix style newlines which looks wierd (no line breaks) in many Windows programs. However, Excel will happily process the information.<\/p>\n<p>The spreadsheet is <a href='http:\/\/www.gssezisoft.com\/main\/wp-content\/uploads\/2011\/09\/QIFtoExcel-Example.xls' rel='attachment wp-att-649'>QIFtoExcel-Example<\/a><\/p>\n<h1>Easy Ways for Lucky People<\/h1>\n<p>If you have installed GnuCash with a MySQL database there is probably an SQL select statement that will export the data in one step.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>It is easy to get information into GnuCash, but getting it out is a different matter.<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[41],"tags":[],"_links":{"self":[{"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/posts\/633"}],"collection":[{"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/comments?post=633"}],"version-history":[{"count":0,"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/posts\/633\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/media?parent=633"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/categories?post=633"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.gssezisoft.com\/main\/wp-json\/wp\/v2\/tags?post=633"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}