[2019-01-30 11:52:41] main.CRITICAL: SQLSTATE[40001]: Serialization failure: 1213 Deadlock found when trying to get lock; try restarting transaction, query was: INSERT INTO
sales_order_grid
(entity_id
,status
,store_id
,store_name
,customer_id
,base_grand_total
,base_total_paid
,grand_total
,total_paid
,increment_id
,base_currency_code
,order_currency_code
,shipping_name
,billing_name
,created_at
,updated_at
,billing_address
,shipping_address
,shipping_information
,customer_email
,customer_group
,subtotal
,shipping_and_handling
,customer_name
,payment_method
,total_refunded
,signifyd_guarantee_status
) SELECT sales_order.entity_id ASentity_id
, sales_order.status ASstatus
, sales_order.store_id ASstore_id
, sales_order.store_name ASstore_name
, sales_order.customer_id AScustomer_id
, sales_order.base_grand_total ASbase_grand_total
, sales_order.base_total_paid ASbase_total_paid
, sales_order.grand_total ASgrand_total
, sales_order.total_paid AStotal_paid
, sales_order.increment_id ASincrement_id
, sales_order.base_currency_code ASbase_currency_code
, sales_order.order_currency_code ASorder_currency_code
, TRIM(CONCAT_WS(' ', IF(sales_shipping_address
.firstname
<> '',sales_shipping_address
.firstname
, NULL), IF(sales_shipping_address
.lastname
<> '',sales_shipping_address
.lastname
, NULL))) ASshipping_name
, TRIM(CONCAT_WS(' ', IF(sales_billing_address
.firstname
<> '',sales_billing_address
.firstname
, NULL), IF(sales_billing_address
.lastname
<> '',sales_billing_address
.lastname
, NULL))) ASbilling_name
, sales_order.created_at AScreated_at
, sales_order.updated_at ASupdated_at
, TRIM(CONCAT_WS(' ', IF(sales_billing_address
.street
<> '',sales_billing_address
.street
, NULL), IF(sales_billing_address
.city
<> '',sales_billing_address
.city
, NULL), IF(sales_billing_address
.region
<> '',sales_billing_address
.region
, NULL), IF(sales_billing_address
.postcode
<> '',sales_billing_address
.postcode
, NULL))) ASbilling_address
, TRIM(CONCAT_WS(' ', IF(sales_shipping_address
.street
<> '',sales_shipping_address
.street
, NULL), IF(sales_shipping_address
.city
<> '',sales_shipping_address
.city
, NULL), IF(sales_shipping_address
.region
<> '',sales_shipping_address
.region
, NULL), IF(sales_shipping_address
.postcode
<> '',sales_shipping_address
.postcode
, NULL))) ASshipping_address
, sales_order.shipping_description ASshipping_information
, sales_order.customer_email AScustomer_email
, sales_order.customer_group_id AScustomer_group
, sales_order.base_subtotal ASsubtotal
, sales_order.base_shipping_amount ASshipping_and_handling
, TRIM(CONCAT_WS(' ', IF(sales_order
.customer_firstname
<> '',sales_order
.customer_firstname
, NULL), IF(sales_order
.customer_lastname
<> '',sales_order
.customer_lastname
, NULL))) AScustomer_name
, sales_order_payment.method ASpayment_method
, sales_order.total_refunded AStotal_refunded
, signifyd_case.guarantee_disposition ASsignifyd_guarantee_status
FROMsales_order
LEFT JOINsales_order_address
ASsales_shipping_address
ON sales_order.shipping_address_id = sales_shipping_address.entity_id LEFT JOINsales_order_address
ASsales_billing_address
ON sales_order.billing_address_id = sales_billing_address.entity_id LEFT JOINsales_order_payment
ON sales_order.entity_id = sales_order_payment.parent_id
-
And... the question is?– Raul SanchezCommented Jan 30, 2019 at 14:38
-
@RaulSanchez did you find the fix for this? I'm facing a similar issue.– Satish GadhaveCommented Nov 21, 2020 at 13:38
-
You'd read the posted answer :)– Raul SanchezCommented Dec 22, 2020 at 7:20
Add a comment
|
1 Answer
Sorry I cannot comment..
It seems like you were running two processes that have attempted to lock the same database table? Perhaps you were re-indexing and trying to run an import simultaneously?
We will need more details to help.