SELECT DISTINCT M.mem_id, B.prod_name, M.mem_name, M.addr
	FROM member M
		LEFT OUTER JOIN buy B
		ON M.mem_id = B.mem_id
	WHERE B.prod_name IS NULL -- 정답
	ORDER BY M.mem_id;
USE market_db;
SELECT DISTINCT M.mem_id, M.mem_name, M.addr
	FROM buy B
		INNER JOIN member M
		ON B.mem_id = M.mem_id
	ORDER BY M.mem_id;
-- 실행한 코드

Untitled