I am have table a that stores created_by and updated_by while both of them just store user_id, while I have table b that stores user_id, and user_name. I cant seems to retrieve the same column with two different criteria. I have two sql that but how to combine both of them
SELECT b.user_name FROM a.created_by WHERE b.created_by = a.user_id
SELECT b.user_name FROM a.updated_by WHERE b.updated_by = a.user_id