1.创建外键


2.多表查询

SELECT * FROM mydb.role,mydb.users where role.userid=2 and role.userid=users.id;




Logo

更多推荐