I have a table with some data
t1
------------------
id (int)
item_id (int)
item_description (text)
showHide (enum 0,1)
Normally I show any results that have showHide flag set to '0'. I need to modify the query to also show results with showHide flag set to '1' if user has the corresponding item_id in another table, t2.
t2
------------------
id (int)
item_id (int)
usr_id (int)
Stuck here, not sure how to do this:
SELECT item_description FROM t1
// get results with showHide = 0
// AND
// showHide = 1 if t1.item_id found in t2 WHERE usr_id = 123