Where is this query run?

Lakjin

Active Member
Hi,

Where is this query run and how can I change it?

SELECT DISTINCT(DATE(t.date_added)) AS date_added, `t`.`log_id` AS `t0_c0` FROM `mw_campaign_delivery_log_archive` `t` INNER JOIN `mw_list_subscriber` `subscriber` ON (`t`.`subscriber_id`=`subscriber`.`subscriber_id`) INNER JOIN `mw_list` `list` ON (`subscriber`.`list_id`=`list`.`list_id`) WHERE (DATE(t.date_added) >= DATE_ADD(LAST_DAY(DATE_SUB(NOW(), INTERVAL 3 MONTH)), INTERVAL 1 DAY)) AND (list.customer_id = 1 AND list.status != 'pending-delete') GROUP BY MONTH(t.date_added) ORDER BY t.date_added ASC LIMIT 3

I don't want any queries touching mw_campaign_delivery_log_archive because I've moved that table to an HDD and any query on it is very slow.

Thanks!
 

Lakjin

Active Member
Thank you. Got it. I've edited out line 323 and made it do just $cdlModel = CampaignDeliveryLog::model();
 
Top