mysql查詢結(jié)果處理,根據(jù)從一個表的查詢結(jié)果再去另一個表查詢?
SELECT classFROM B WHERE name = (select name from A where id = xxxx)即可如果一個id對應(yīng)多個nameSELECT classFROM B WHERE name IN (select name from A where id = xxxx)
SELECT classFROM B WHERE name = (select name from A where id = xxxx)即可如果一個id對應(yīng)多個nameSELECT classFROM B WHERE name IN (select name from A where id = xxxx)