Differenciating Invoices and Bills

John Ralls jralls at ceridwen.us
Thu Mar 6 13:03:47 EST 2014


On Mar 6, 2014, at 8:23 AM, Nestor Stura <nestor.stura at gmail.com> wrote:

> Hi all,
> I am building some reports based on business tables, with MSAccess and SQlite3.
> I have the following doubt, Client's invoices and Vendor's bills are
> kept on the same table, I could  not find any field that differentiate
> both.
> Is there any way in this table to split them or should I access via
> Customers and Vendors tables?
> Thanks for any help.

You can use the owner_type field to distinguish them: 2 means the invoice is to a customer and 4 means that it’s from a vendor.
If you want to report on a particular customer or vendor, you’ll need to join owner and invoices on owner.GUID = invoices.owner_guid specifying customer_guid or vendor_guid in your WHERE clause.

Regards,
John Ralls




More information about the gnucash-user mailing list