In case you have your own slow SQL query, you can optimize it automatically here.
For the query above, the following recommendations will be helpful as part of the SQL tuning process.
You'll find 3 sections below:
ALTER TABLE `table1` ADD INDEX `table1_idx_id` (`id`);
ALTER TABLE `table1` ADD INDEX `table1_idx_testid` (`testid`);
ALTER TABLE `table1` ADD INDEX `table1_idx_band_date` (`band`,`date`);
WITH t AS (SELECT
table1.id
FROM
table1
WHERE
table1.testid IN (SELECT
table1.testid
FROM
table1
WHERE
table1.date BETWEEN '2020-06-01' AND '2020-07-01'
AND table1.band = 3)) SELECT
a.data1
FROM
table1 a
WHERE
a.id = t.id