Plug-ins > FM Books Connector Online

Query open invoice for specific Customer


Scott Toland:
I am trying to find only open invoices in QBOnline for a specific customer, I can find all invoices for a specific customer, but how do I return only open invoices?

PCQO_RqNew("Query", "Invoice)
PCQO_ReqAddFieldWithValue("CustomerRef"; Customer ID Field)

This finds all for a customer, What do I add to just find open ones?



Jeff Henry:
Hi Scott,

Since there doesn't appear to be a status field in the XML response for an Invoice, you may need to use:

PCQO_RqNew ( "Query" ; "Invoice" )
PCQO_RqAddFieldWithValue ( "CustomerRef" ; Customer ID Field )
PCQO_RqAddFieldWithValue ( "QueryString" ; "SELECT * FROM Invoice WHERE Balance > '0' " )

This uses a SQL-style query to perform comparisons of field values instead of strictly matching values.

Let me know if this helps.

- Jeff

Scott Toland:

Thanks for the info.  I just didn't know how to do that.

I will give that a shot.

Thanks again.


Scott Toland:
Is it possible to make a payment to a specific Invoice# (Not TxnID).  I suppose I could do a query for that invoice# and grab the TxnID and then submit it using that TxnID, but it would be easier to just make the  payment to the Invoice# (document Number).

Thanks for you help!



[0] Message Index

Go to full version