Difference between revisions of "gnucash mysql invoice query"

From thelinuxwiki
Jump to: navigation, search
Line 10: Line 10:
 
  +----------------------------------+
 
  +----------------------------------+
 
  1 row in set (0.00 sec)
 
  1 row in set (0.00 sec)
 +
 +
mysql> '''SELECT date,description,action,quantity_num,i_price_num,i_discount_num,i_disc_type,i_taxable FROM gnucash_database.entries WHERE invoice = "f32b43b6da2b19e4e9e838d30ffc1edb";'''
 +
 +
[[category:gnucash]]

Revision as of 14:51, 24 May 2013

CLI queries for gnucash invoice data

get invoice guid

mysql> SELECT guid FROM gnucash_database.invoices WHERE id = "2013018";
+----------------------------------+
| guid                             |
+----------------------------------+
| f32b43b6da2b19e4e9e838d30ffc1edb |
+----------------------------------+
1 row in set (0.00 sec)

mysql> SELECT date,description,action,quantity_num,i_price_num,i_discount_num,i_disc_type,i_taxable FROM gnucash_database.entries WHERE invoice = "f32b43b6da2b19e4e9e838d30ffc1edb";