SQL查询A表不包括B表的相同字段的语句
select Events.title,VS_USER.USER_NAME from Events full join VS_USER on Events.id=VS_USER.user_id
//not exists写法
select * from Events where not exists (select * from VS_USER where Events.Id=VS_USER.USER_ID )
//not in 写法
select * from Events where Events.Id not in (select VS_USER.USER_ID from VS_USER where Events.Id=VS_USER.USER_ID )
推荐用后者
效率高,而且没有数据条数的限制