i have album table and album permission table.
album album_id name private (values yes or no)
album permission id album_id user_id
**albums**
album_id name private
1 family yes
2 friend no
3 outdoor pic yes
**album permission**
id album_id user_id
1 3 5
now i want to get all the album list, which i have permission of. which means if album.private = no or if my id (5) exist in the permission table, then the row should be in the list, else it should not show in the list.
following should show me in the result
**albums result set**
album_id name private
2 friend no
3 outdoor pic yes -- < this showing me, because i exist in the permission table