I have 2 table(example A and B)
A
-----------
id | name
-----------
1 | Bruce
2 | Peter
3 | Jack
4 | Alin
---------------------
id | status | A_id
---------------------
1 | 0 | 1
2 | 0 | 3
------------
id | name
------------
2 | Peter
4 | Alin
Please give a try. Your C
is a records that not shown from B
right?
SELECT * From table a where id NOT IN (SELECT a_id from B)