欢迎投稿

今日深度:

MySQL的join使用,

MySQL的join使用,


#内连接
select * from auth_user u inner join auth_group g on u.id = g.id;

#左连接
select * from auth_user a left join auth_group b on a.id = b.id;

#右连接
select * from auth_user a right join auth_group b on a.id = b.id;

#左链接-内连接
select * from auth_user a left join auth_group b on a.id = b.id where b.id is null;

#右连接-内连接
select * from auth_user a right join auth_group b on a.id = b.id where b.id is null;

#MySQL外连接不让使用full join 或者full outer join

www.htsjk.Com true http://www.htsjk.com/Mysql/39913.html NewsArticle MySQL的join使用, #内连接 select * from auth_user u inner join auth_group g on u.id = g.id; #左连接 select * from auth_user a left join auth_group b on a.id = b.id; #右连接 select * from auth_user a right join auth_group b on a...
相关文章
    暂无相关文章
评论暂时关闭