SELECT tise.systemId FROM tbl_iss_system_extend_info tise
LEFT JOIN tbl_iss_plat_system_info tisp ON tise.systemId = tisp.systemId
WHERE tise.fieldValue="122.224.65.194" AND tisp.isDelete=0;
selcet * from table_A A LEFT JOIN table_B B ON A.systemid=B.systemid
WHERE A.fieldValue="122.224.65.194" AND B.isDelete=0;
意思是:
表A和表B根据systemid组成一张大表,表的字段为A、B的并集,然后以A表的fieldValue="122.224.65.194" 和 B表的isDelete=0进行重新筛选
A表:
B表:
A+B
如上表,以表A为准,进行扩展,如果B表中没有对应的值,则值为Null
再进行where子句进行筛选
如需要多个表联合查询,则在left join 下面继续输入联合查询表