The following select query from my application is taking more than 200ms. The table has around 2 million rows. Is there any ways to improve the performance of this query ?
select count(id) from table1 where status='A' and empID=123
Table Indexes
PRIMARY KEY (`id`),
KEY `empID` (`empID`),
KEY `status` (`status`),
KEY `testID` (`testID`),
CONSTRAINT `fk_1` FOREIGN KEY (`empID`) REFERENCES `emp_info` (`id`)