So I have query with the following where statement. Basically, I want to ensure there was no sports or player activity within the last 7 days.
WHERE......
AND (( (SELECT max(sportswagerbyleague.asOfDate)
FROM sportswagerbyleague
WHERE sportswagerbyleague.userID = customer_profile.userID)
<= date(CURDATE()) - INTERVAL 7 DAY )
AND ((SELECT max(pa.txndate)
FROM player_activity pa
WHERE pa.userID = customer_profile.userID) <= date(CURDATE()) - INTERVAL 7 DAY ) )
However, if there is a NULL value (aka that user either has no player activity or sports activity), then the WHERE statement becomes false for that particular user. I want the WHERE statement to remain true even for a single NULL value.
Suggestions?