select NameCompany from [ParticipateFairList]
where IdFair=(select Id from [TmpFair] where Parent_FK=88)
这是正确的吗?
如何
For Select * From [Table] where ID=`List` or `SubQuery`
答案 0 :(得分:1)
select NameCompany from [ParticipateFairList]
where IdFair in (select Id from [TmpFair] where Parent_FK=88)
其中IdFair在(...)而不是IdFair =(...)
答案 1 :(得分:0)
对于MySQL或SQL Server,您需要expr IN (list | subquery)
。