cancel
Showing results for 
Search instead for 
Did you mean: 

Rate in row should have matched document rate

xinerji
Explorer
722

Hello,

Sometimes I want to use different exchange rates from the ORTT table.

when I send USD rate at DocumentLines I get error.

(I don't get an error when I send the Euro rate.)

Do you have a solution?

Request:

https://ip:50000/b1s/v1/Invoices

{ "CardCode" : "C000000162", "CardName" : "CUST NAME", "DocCurrency" : "TRY", "DocRate" : "1", "BPLId" : "165", "DocDate" : "2019-11-15", "DocDueDate" : "2019-12-30", "TaxDate" : "2019-11-15", "Comments" : "", "DiscPrcnt" : "0", "DocStatus" : "O", "GroupNum" : "45", "DocumentLines" : [ { "ItemCode" : "HZM10000", "Quantity" : "1", "Price" : "100", "Currency" : "USD", "Rate" : "6", "DiscPrcnt" : "0", "VatGroup" : "S01", "TotalSumSy" : "100", "UomCode" :"piece" } ] }

Response:

{ "error": { "code": -10, "message": { "lang": "en-us", "value": "Rate in row should have matched document rate. " } } }

Best regards

Ahmet Pehlivan

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member566317
Active Participant

Youy business partner has currency in EURO. therefore when you are passing currency in USD then its giving ERROR.your business partner currency automatically come on transaction document and according to transaction document currency you can pass currency at line level.

xinerji
Explorer
0 Kudos

Business partner has currency=All Currencies

Johan_Hakkesteegt
Active Contributor
0 Kudos

Hi Ahmet,

Please set the currency of the BP to All Currencies.

Regards,

Johan

xinerji
Explorer
0 Kudos

hi johan,

Business partner has currency=All Currencies

I can send Eur or other exchange rates

I can't send only USD exchange rate different from "ORTT" table.

thanks

Ahmet

Johan_Hakkesteegt
Active Contributor
0 Kudos

Hi Ahmet,

Please also set the document currency (OINV.CurSource) to BP Currency.

Regards,

Johan

xinerji
Explorer
0 Kudos

hi Johan,

I tried three but I get same response.

OINV.CurSource

C=BP Currency, L=Local Currency, S=System Currency

Thanks

Ahmet

Johan_Hakkesteegt
Active Contributor
0 Kudos

Hi Ahmet,

Did you use the value C ?

Regards,

Johan

xinerji
Explorer
0 Kudos

Hi Johan,

Yes, "CurSource":"C"

Request:

{"U_LGSFT_eFatNum":"ETRU201900001002","CardCode":"C000000162","CardName":"Customer ", "DocCurrency":"TRY","DocRate":1.0,"BPLId":165,"DocDate":"2019-11-27","DocDueDate":"2019-12-22", "TaxDate":"2019-11-27","Comments":"","DiscPrcnt":0,"DocStatus":"O","GroupNum":"25", "CurSource":"C","XiOperationType":"TRUCK","XiTransportDirection":"D", "xiOperationName":"","XiFirm":"164", "DocumentLines":[ {"ItemCode":"HZM10000", "Quantity":1.0,"Price":100.00, "Currency":"USD", "Rate":5.7486, "DiscPrcnt":0, "VatGroup":"S01", "TotalSumSy":100.00, "UomCode":"piece", "XiOperationType":"TRUCK"} ] }

***

Business partner

"CardCode" : "C000000162"

"Currency" : "##"

Johan_Hakkesteegt
Active Contributor
0 Kudos

Hi Ahmet,

Could you please test adding this order manually, to see if the B1 client throws the same error?

Regards,

Johan

xinerji
Explorer
0 Kudos

Hi joan,

I can't change USD exchange rate at invoice line. Input is closed.

I can change EUR exchange rate. input is open.

Thanks

Ahmet

Johan_Hakkesteegt
Active Contributor
0 Kudos

Hi Ahmet,

Please check SAP notes, to see if this is a known issue, but this may be a case for SAP support.

Regards,

Johan

xinerji
Explorer
0 Kudos

Hi Johan,

Thank you for your interest.

https://ip:50000/b1s/v1/SBOBobService_GetLocalCurrency

response: TRY

https://ip:50000/b1s/v1/SBOBobService_GetSystemCurrency

response:USD

Do you know how can I set System Currency USD to TRY ?

Maybe I can change USD exchange rate in invoice.

Regards

Ahmet Pehlivan

Johan_Hakkesteegt
Active Contributor
0 Kudos

Hi Ahmet,

Again, I recommend testing the principle manually in the B1 client. This will tell you if this is possible in the B1 system. If it is possible then you can just test it in your application.

Regards,

Johan