[
https://issues.apache.org/jira/browse/OFBIZ-13093?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Anil K Patel closed OFBIZ-13093.
--------------------------------
Assignee: Anil K Patel
Resolution: Cannot Reproduce
I updated the preferred currency (China) of DemoSupplier.
Then I created Vendor Payment in Company default currency (USD)
Cannot reproduce.
> Payment to Supplier with non default currency generates an error
> ----------------------------------------------------------------
>
> Key: OFBIZ-13093
> URL: https://issues.apache.org/jira/browse/OFBIZ-13093
> Project: OFBiz
> Issue Type: Bug
> Components: accounting
> Affects Versions: 18.12.13
> Reporter: Pierre Smits
> Assignee: Anil K Patel
> Priority: Major
>
> When creating a payment to a supplier that has a different currency than
> default for the OFBiz setup (in demo stable: EuroSupplier, following error is
> shown:
> {code:java}
> The Following Errors Occurred:Exception thrown while creating the "payment"
> GenericValue: org.apache.ofbiz.entity.GenericEntityException: Error while
> inserting:
> [GenericEntity:Payment][amount,100(java.math.BigDecimal)][comments,paper
> toner(java.lang.String)][createdStamp,2024-05-18
> 07:35:11.375(java.sql.Timestamp)][createdTxStamp,2024-05-18
> 07:35:11.35(java.sql.Timestamp)][currencyUomId,USD(java.lang.String)][effectiveDate,2024-05-18
> 07:35:11.375(java.sql.Timestamp)][lastUpdatedStamp,2024-05-18
> 07:35:11.375(java.sql.Timestamp)][lastUpdatedTxStamp,2024-05-18
> 07:35:11.35(java.sql.Timestamp)][overrideGlAccountId,null()][partyIdFrom,Company(java.lang.String)][partyIdTo,euro(java.lang.String)][paymentId,10001(java.lang.String)][paymentMethodId,ABN_CHECKING(java.lang.String)][paymentMethodTypeId,COMPANY_CHECK(java.lang.String)][paymentRefNum,1(java.lang.String)][paymentTypeId,VENDOR_PAYMENT(java.lang.String)][statusId,PMNT_NOT_PAID(java.lang.String)]
> (SQL Exception while executing the following:INSERT INTO OFBIZ.PAYMENT
> (PAYMENT_ID, PAYMENT_TYPE_ID, PAYMENT_METHOD_TYPE_ID, PAYMENT_METHOD_ID,
> PAYMENT_GATEWAY_RESPONSE_ID, PAYMENT_PREFERENCE_ID, PARTY_ID_FROM,
> PARTY_ID_TO, ROLE_TYPE_ID_TO, STATUS_ID, EFFECTIVE_DATE, PAYMENT_REF_NUM,
> AMOUNT, CURRENCY_UOM_ID, COMMENTS, FIN_ACCOUNT_TRANS_ID,
> OVERRIDE_GL_ACCOUNT_ID, ACTUAL_CURRENCY_AMOUNT, ACTUAL_CURRENCY_UOM_ID,
> LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP)
> VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
> (INSERT on table 'PAYMENT' caused a violation of foreign key constraint
> 'PAYMENT_TPTY' for key (euro). The statement has been rolled back.)) (Error
> while inserting:
> [GenericEntity:Payment][amount,100(java.math.BigDecimal)][comments,paper
> toner(java.lang.String)][createdStamp,2024-05-18
> 07:35:11.375(java.sql.Timestamp)][createdTxStamp,2024-05-18
> 07:35:11.35(java.sql.Timestamp)][currencyUomId,USD(java.lang.String)][effectiveDate,2024-05-18
> 07:35:11.375(java.sql.Timestamp)][lastUpdatedStamp,2024-05-18
> 07:35:11.375(java.sql.Timestamp)][lastUpdatedTxStamp,2024-05-18
> 07:35:11.35(java.sql.Timestamp)][overrideGlAccountId,null()][partyIdFrom,Company(java.lang.String)][partyIdTo,euro(java.lang.String)][paymentId,10001(java.lang.String)][paymentMethodId,ABN_CHECKING(java.lang.String)][paymentMethodTypeId,COMPANY_CHECK(java.lang.String)][paymentRefNum,1(java.lang.String)][paymentTypeId,VENDOR_PAYMENT(java.lang.String)][statusId,PMNT_NOT_PAID(java.lang.String)]
> (SQL Exception while executing the following:INSERT INTO OFBIZ.PAYMENT
> (PAYMENT_ID, PAYMENT_TYPE_ID, PAYMENT_METHOD_TYPE_ID, PAYMENT_METHOD_ID,
> PAYMENT_GATEWAY_RESPONSE_ID, PAYMENT_PREFERENCE_ID, PARTY_ID_FROM,
> PARTY_ID_TO, ROLE_TYPE_ID_TO, STATUS_ID, EFFECTIVE_DATE, PAYMENT_REF_NUM,
> AMOUNT, CURRENCY_UOM_ID, COMMENTS, FIN_ACCOUNT_TRANS_ID,
> OVERRIDE_GL_ACCOUNT_ID, ACTUAL_CURRENCY_AMOUNT, ACTUAL_CURRENCY_UOM_ID,
> LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP)
> VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
> (INSERT on table 'PAYMENT' caused a violation of foreign key constraint
> 'PAYMENT_TPTY' for key (euro). The statement has been rolled back.))) {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)