I already tried various types of JOINS but I am not able to get this simple query to work. I would like to have the result of table a in any case, even if there is no corresponding entry in table b. I tried:
SELECT a.user_id,
a.user_name,
b.first_name
FROM users a
LEFT OUTER JOIN members b
ON a.member_uid = b.uid
WHERE (a.user_name = 'TEST'
AND b.active = 1)
In this case, there is no entry in b that has b.active = 1. But I assumed that all wanted columns from a would be returned and the column from b would be null. But when running this query in the SQL window of the MariaDB, zero rows are returned.
Any help would be highly appreciated!!