有两个表tb1,tb2,我要列出tb2中的字段name的内容,要求是如果tb1中也有该名字,则不列出。 怎么没人帮我看看这积压SQL语句的写法啊 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 根据我的理解:select name from tb2 where tb2.name not in (Select DISTINCT(name) from tb1) Select * From tb1 Where name Not In(Select name From tb2) Select * From tb1 Where name Not In(Select name From tb2)这句话在语法上是有毛病的 只能确定楼主的错误。楼上们的,就不清楚了。照葫芦画瓢就应该是这样:select name from tb2 where name not in (Select DISTINCT(name) from tb1) not in (括号中只能是以逗号分开的语句才行,可是现在好象并没有分开啊) php学到什么程度才可以应付一般的项目 查询一个数值在数据库里出现的概率。 php数据编码问题 新手跪求!!处理数据库数据!求大神帮助!! PHP可以调用哪些图形库? 大家评价下一下这个SNS网站怎样? Linux 下有什么好的PHP编辑器 ! 我刚才写了一个留言程序,可是老是显示不出来呢称,序列号,和留言的正文,我看不出来有问题,大家看看! [^a-zA-Z0-9\u4e00-\u9fa5\s]我用这个匹配符号,php 中preg_replace总是报错,怎么破? 请教一个PHPExcel问题 求助 站点日历 代码! 通用表单生成程序(php+mysql)
select name from tb2 where tb2.name not in (Select DISTINCT(name) from tb1)
这句话在语法上是有毛病的
select name from tb2 where name not in (Select DISTINCT(name) from tb1)