Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
2 Odpowiedzi
2035 Widoki

We need to make a calculation of the total price of all partner orders between two dates . How can we use the API to make a query to accept this result ?

technical details:

We use the API with XML-RPC.

version 9.0 .
Awatar
Odrzuć
Autor Najlepsza odpowiedź

The problem is that one partner can have hundreds of thousands of orders per month. And if we'll fetch the full order object it will be bad for performance. can we fetch only the specific "amount_total" field without rest of data ? or alternatively there is a query that makes this sum calculation ?

Awatar
Odrzuć
Najlepsza odpowiedź

amount_total is the field that saves the net amount of partner orders. so you have to find the summation of this field after fetching orders in between date range. for the date, you can query either with the create_date of record or order date [date_order].

Awatar
Odrzuć