Performance issues, bad table design
-
Major MySQL performance hog from queries like
SELECT * FROM wp_sfa_abandoned_carts WHERE customer_key= ? AND cart_is_recovered = ? AND order_id IS NULL LIMIT ?
as the table has no proper indexes:explain wp_sfa_abandoned_carts; +-----------------------+---------------+------+-----+---------+----------------+ | Field | Type | Null | Key | Default | Extra | +-----------------------+---------------+------+-----+---------+----------------+ | id | int(11) | NO | PRI | NULL | auto_increment | | customer_key | char(32) | NO | | NULL | | | cart_contents | longtext | NO | | NULL | | | cart_expiry | bigint(20) | NO | | NULL | | | cart_is_recovered | tinyint(1) | NO | | NULL | | | ip_address | char(32) | YES | | NULL | | | item_count | int(11) | NO | | NULL | | | order_id | int(11) | YES | | NULL | | | viewed_checkout | tinyint(1) | NO | | 0 | | | show_on_funnel_report | tinyint(1) | NO | | 0 | | | cart_total | decimal(15,2) | YES | | NULL | | +-----------------------+---------------+------+-----+---------+----------------+
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Performance issues, bad table design’ is closed to new replies.