I have a mysql query like this
SELECT * FROM table_a LEFT JOIN table_b ON table_a.id = table_b.id WHERE table_b.status != \'1\' AND (table_b.date IS NULL OR