Open piranout opened 10 years ago
Is it possible that you have more than 1000 Invoices from 2014-05? I think its likely since you are asking for the InvoiceItem table.
No, there are under 300 invoices in this period. Under 350 invoice items as well. There are no "Get" methods on the Invoice service, so I can't use that as a working reference to compare the raw RPC calls. I did compare the Invoice & InvoiceItem calls against a Company and Contact RPC calls that work as expected, and I don't see any significant structural differences in the XML.
Hi there.
Your code is fine... Numbering starts at 0.
try page = 0.
my code is and works.. var queryData = new XmlRpcStruct() { { "DateCreated", "2015%" } }; var invoiceItems = client.DataService.Query( table: "InvoiceItem", limit: 1000, page: 0, queryData: queryData, selectedFields: new[] { "Id" //, "InvoiceAmt", "DateCreated", "Description", "Discount", "OrderItemId"//, "CustomFields" }) .ToList();
I would expect this query to return every InvoiceItem from 2014. Instead, it returns only items created this month, 2014-05. It's worse for Invoice; no records are returned for any query I've been able to craft yet. (In contrast, Companies & Contacts produce exactly the expected query results.)