I am getting issue on exporting the selected credit memo grid. It is only occurring with the credit memo. Other export is working fine with shipment, invoice, and order.
I am also attaching the error screenshot.
credit memo
I am getting issue on exporting the selected credit memo grid. It is only occurring with the credit memo. Other export is working fine with shipment, invoice, and order.
I am also attaching the error screenshot.
credit memo
2
Answers
You have an SQL query error while exporting the Credit memo data, it happens whenever you something deleted a record in your database.
Can you please elaborate on more steps:
-Did you delete some orders associated with the credit memo?
-Did you delete some invoices of any order?
Please check and confirm also check the record with entity_id = 1052 in your database table. Run the below query:
Maybe another way to fix this is if you have added a third-party module that has its own Credit memo Grid within the module to show placed credit memo of each order. This is also conflicting because it is using entity_id from sales_creditmemo_grid as well.
Error: SQLSTATE[23000]: Integrity constraint violation: 1052 Column ‘entity_id’ in where clause is ambiguous.
So, you can try in your credit memo collection file and change the method like:
Replaced this:
With this:
Now all is well! No conflicts!