Below is my SQL code:
select count(1)
from customers
where id in(
select custid
from accounts
where sid in(72,73,74,75,76,77,78,79)
)
and id not in(
select custid
from accounts
where sid in(80,81)
);
Tables are indexed properly. Can this code be rewritten for better performance?