mysql - sql query of not filling table entry -
write query display name , role details of users have filled in profile details, sorted name in ascending order. question query follows:
select name, role.name, role.id user,role user.profile_id= profile.id , profile_id in (select id profile address not null , batch not null , degree_id not null , designation not null , gender not null) order name asc but query not working,please suggest way correct query question
try this, or provide information schema hard create queries blindly.
select user.name, role.name, role.id user u inner join role r on u.role_id = r.id inner join profie p on u.profile_id = p.profile_id address not null , batch not null , degree_id not null , designation not null , gender not null the main problem trying join role without joining table.
i have made join between user , role question didn't show relationship. tweak necessary.
Comments
Post a Comment