mysql 關系表查詢,根據從一個表的查詢結果再去另一個表查詢?
SELECT classFROM B WHERE name = (select name from A where id = xxxx)即可如果一個id對應多個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對應多個nameSELECT classFROM B WHERE name IN (select name from A where id = xxxx)