INNER JOIN
adalah pendekatan yang tepat.
Kuerinya adalah
SELECT user.id, user.name, user.status
FROM table1 AS user
INNER JOIN table2 AS service1 ON service1.sid = user.id
INNER JOIN table3 AS service2 ON service2.oid = user.id
WHERE service1.status = 1 AND service2.status = 1
Jika Anda ingin pengguna yang menggunakan layanan1 ATAU layanan2, kuerinya dapat berupa
SELECT user.id, user.name, user.status
FROM table1 AS user
WHERE user.id IN (SELECT sid FROM table2 WHERE status=1) OR
user.id IN (SELECT oid FROM table3 WHERE status=1)