Harvey Pham
Harvey Pham

Reputation: 635

Order the result set from QuickBooks Desktop

We synchronize data from QuickBooks Desktop to our web service. For every session, we want to pick only new and modified data (compare to data in the database). So, we set FromModifiedDate filter and set it to the latest modified time of records in our database.

The problem is that data returns is not in order of ModifiedTime. QuickBooks desktop can return the latest record to us. Assume that there are n records in the result set, with ModifiedTime t1 to tn (where tn is the latest). On first iteration, QuickBooks might return record n (ModifiedTime = tn) and we saved it to the database. There is an interruption on the next iteration. On the next run we ask for record from tn, and miss all records that has not synchronized on the previous run (t1, ...).

Is there a way to specifies that the result set is ordered by ModifiedTime and always returned oldest modified records first? (e.g, first iteration, t1-t5, next t6-t10)

Upvotes: 1

Views: 55

Answers (1)

Keith Palmer Jr.
Keith Palmer Jr.

Reputation: 27962

Is there a way to specifies that the result set is ordered by ModifiedTime and always returned oldest modified records first? (e.g, first iteration, t1-t5, next t6-t10)

No, QuickBooks desktop does not support this.

It sounds like this isn't really your issue though. Can you clarify what you mean by:

There is an interruption on the next iteration.

What do you mean "an interruption"? What sort of interruption are you anticipating? You should be processing every record you get back, every time. Remove the "interuption" from your application and you won't have any issues, right?

Upvotes: 2

Related Questions