Ik krijg een foutmelding:
itgenoda137
De Exact Online-server kan of wil het verzoek niet verwerken vanwege een kennelijke clientfout (bijv. verkeerd opgemaakte verzoeksyntaxis, grootte te groot, ongeldige verzoekberichtframing of misleidende verzoekroutering). Bericht:.
The remote server returned an error: (400) Bad Request.
bij het ophalen van de volgende OData4 link:
/acme-exact-online5/odata4/ExactOnlineREST.Financial.GLAccountsBulk@eol?$filter=Division eq 843506 and ID eq e65ea42b-3e24-4786-afb2-01adc65c0e3f or Division eq 843506 and ID eq f3cc6ca3-5624-4ab2-9875-01ca2b0d82a9 or Division eq 843506 and ID eq a3577378-d43f-464d-91e7-075c879e01cb or Division eq 843506 and ID eq a3fd1adc-8f4d-4552-98e7-07923edab5c4 or Division eq 843506 and ID eq 97bd161c-bab3-4654-8a1e-0974d89e0426 or Division eq 843506 and ID eq 60a43114-a111-407d-acc1-0a8b2acf401c or Division eq 843506 and ID eq fa0b57e1-be80-4dab-925c-0ba18d6819bd or Division eq 843506 and ID eq 79846997-3f3a-4a51-a040-160c4e0120fd or Division eq 843506 and ID eq 40b4ac82-7037-44b7-b59e-1a2f39b3283c or Division eq 843506 and ID eq 0c65f7cd-d903-4c7e-9a4f-2c2d70d275e2 or Division eq 843506 and ID eq b563cded-4ef1-4d84-b4fb-314af6c5d230 or Division eq 843506 and ID eq d45a78f7-084e-4bcb-94df-36f0695a844a or Division eq 843506 and ID eq 400d2a73-fd1d-452c-a265-395df2909d4d or Division eq 843506 and ID eq 5f7c3b28-650f-4afa-aefb-3aea4e8d6bce or Division eq 843506 and ID eq 1aeaeeec-8f6e-4119-8de0-3f25dccef81c or Division eq 843506 and ID eq b333ce4e-8616-40af-b226-49ce15985e09 or Division eq 843506 and ID eq e0181d73-3474-41a5-8f6b-4ee0c63acfd9 or Division eq 843506 and ID eq 972b13b5-e68c-4e22-87b2-594d139a759e or Division eq 843506 and ID eq 4bb98c85-367b-46fc-9424-5fdb8ad27943 or Division eq 843506 and ID eq 2317996c-60af-40c2-a3f7-620384c04177 or Division eq 843506 and ID eq 1ee07f61-3b6d-4999-a0cf-6935387c7870 or Division eq 843506 and ID eq d628464c-9eee-41a4-a683-6c89c3854ccc or Division eq 843506 and ID eq c66028cb-2a26-4222-a578-720dd782cbe5 or Division eq 843506 and ID eq 1521fb47-012a-41f1-863d-72f74f75b51c or Division eq 843506 and ID eq 97dcb459-d726-4049-848b-73962dc660cf
Dit leidt tot een UniversalSQL-query:
select t.*
from ExactOnlineREST.Financial.GLAccountsBulk@eol t
where ([Division] = :w1 and [ID] = :w2)
or ([Division] = :w3 and [ID] = :w4)
or ([Division] = :w5 and [ID] = :w6)
or ([Division] = :w7 and [ID] = :w8)
or ([Division] = :w9 and [ID] = :w10)
or ([Division] = :w11 and [ID] = :w12)
or ([Division] = :w13 and [ID] = :w14)
or ([Division] = :w15 and [ID] = :w16)
or ([Division] = :w17 and [ID] = :w18)
or ([Division] = :w19 and [ID] = :w20)
or ([Division] = :w21 and [ID] = :w22)
or ([Division] = :w23 and [ID] = :w24)
or ([Division] = :w25 and [ID] = :w26)
or ([Division] = :w27 and [ID] = :w28)
or ([Division] = :w29 and [ID] = :w30)
or ([Division] = :w31 and [ID] = :w32)
or ([Division] = :w33 and [ID] = :w34)
or ([Division] = :w35 and [ID] = :w36)
or ([Division] = :w37 and [ID] = :w38)
or ([Division] = :w39 and [ID] = :w40)
or ([Division] = :w41 and [ID] = :w42)
or ([Division] = :w43 and [ID] = :w44)
or ([Division] = :w45 and [ID] = :w46)
or ([Division] = :w47 and [ID] = :w48)
or ([Division] = :w49 and [ID] = :w50)
Dit leidt tot een Exact Online API-call:
https://start.exactonline.be/api/v1/843506/bulk/financial/GLAccounts?$select=AllowCostsInSales,AssimilatedVATBox,BalanceSide,BalanceType,BelcotaxType,Code,Compress,Costcenter,CostcenterDescription,Costunit,CostunitDescription,Created,Creator,CreatorFullName,CustomField,Description,DescriptionTermID,ExcludeVATListing,ExpenseNonDeductiblePercentage,ID,IsBlocked,Matching,Modified,Modifier,ModifierFullName,PrivateGLAccount,PrivatePercentage,ReportingCode,RevalueCurrency,SearchCode,Type,TypeDescription,UseCostcenter,UseCostunit,VATCode,VATDescription,VATGLAccountType,VATNonDeductibleGLAccount,VATNonDeductiblePercentage,VATSystem,YearEndCostGLAccount,YearEndReflectionGLAccount&$filter=(ID eq guid'97dcb459-d726-4049-848b-73962dc660cf' or (ID eq guid'1521fb47-012a-41f1-863d-72f74f75b51c' or (ID eq guid'c66028cb-2a26-4222-a578-720dd782cbe5' or (ID eq guid'd628464c-9eee-41a4-a683-6c89c3854ccc' or (ID eq guid'1ee07f61-3b6d-4999-a0cf-6935387c7870' or (ID eq guid'2317996c-60af-40c2-a3f7-620384c04177' or (ID eq guid'4bb98c85-367b-46fc-9424-5fdb8ad27943' or (ID eq guid'972b13b5-e68c-4e22-87b2-594d139a759e' or (ID eq guid'e0181d73-3474-41a5-8f6b-4ee0c63acfd9' or (ID eq guid'b333ce4e-8616-40af-b226-49ce15985e09' or (ID eq guid'1aeaeeec-8f6e-4119-8de0-3f25dccef81c' or (ID eq guid'5f7c3b28-650f-4afa-aefb-3aea4e8d6bce' or (ID eq guid'400d2a73-fd1d-452c-a265-395df2909d4d' or (ID eq guid'd45a78f7-084e-4bcb-94df-36f0695a844a' or (ID eq guid'b563cded-4ef1-4d84-b4fb-314af6c5d230' or (ID eq guid'0c65f7cd-d903-4c7e-9a4f-2c2d70d275e2' or (ID eq guid'40b4ac82-7037-44b7-b59e-1a2f39b3283c' or (ID eq guid'79846997-3f3a-4a51-a040-160c4e0120fd' or (ID eq guid'fa0b57e1-be80-4dab-925c-0ba18d6819bd' or (ID eq guid'60a43114-a111-407d-acc1-0a8b2acf401c' or (ID eq guid'97bd161c-bab3-4654-8a1e-0974d89e0426' or (ID eq guid'a3fd1adc-8f4d-4552-98e7-07923edab5c4' or (ID eq guid'e65ea42b-3e24-4786-afb2-01adc65c0e3f' or (ID eq guid'f3cc6ca3-5624-4ab2-9875-01ca2b0d82a9') or ID eq guid'a3577378-d43f-464d-91e7-075c879e01cb')))))))))))))))))))))))
welke genoemde itgenoda137
foutmelding geeft.
Workaround
Inkorten lost de error op:
select t.*
from ExactOnlineREST.Financial.GLAccountsBulk@eol t
where ([Division] = :w1 and [ID] = :w2)
or ([Division] = :w3 and [ID] = :w4)
or ([Division] = :w5 and [ID] = :w6)
or ([Division] = :w7 and [ID] = :w8)
or ([Division] = :w9 and [ID] = :w10)
or ([Division] = :w11 and [ID] = :w12)
or ([Division] = :w13 and [ID] = :w14)
or ([Division] = :w15 and [ID] = :w16)
or ([Division] = :w17 and [ID] = :w18)
or ([Division] = :w19 and [ID] = :w20)
or ([Division] = :w21 and [ID] = :w22)
or ([Division] = :w23 and [ID] = :w24)
or ([Division] = :w25 and [ID] = :w26)
or ([Division] = :w27 and [ID] = :w28)
Toevoeging van een enkele regel genereert weer de foutmelding:
select t.*
from ExactOnlineREST.Financial.GLAccountsBulk@eol t
where ([Division] = :w1 and [ID] = :w2)
or ([Division] = :w3 and [ID] = :w4)
or ([Division] = :w5 and [ID] = :w6)
or ([Division] = :w7 and [ID] = :w8)
or ([Division] = :w9 and [ID] = :w10)
or ([Division] = :w11 and [ID] = :w12)
or ([Division] = :w13 and [ID] = :w14)
or ([Division] = :w15 and [ID] = :w16)
or ([Division] = :w17 and [ID] = :w18)
or ([Division] = :w19 and [ID] = :w20)
or ([Division] = :w21 and [ID] = :w22)
or ([Division] = :w23 and [ID] = :w24)
or ([Division] = :w25 and [ID] = :w26)
or ([Division] = :w27 and [ID] = :w28)
or ([Division] = :w29 and [ID] = :w30)
Blijkbaar zijn 60 condities/operatoren voldoende om de Exact Online-API een Bad Request te laten geven.