Mestika
10/14/2015 - 6:43 AM

SQL (MySQL): Query at least one of something

SQL (MySQL): Query at least one of something

#http://stackoverflow.com/questions/3197322/sql-query-at-least-one-of-something

SELECT u.*
  FROM USERS u
  WHERE EXISTS(SELECT NULL
    FROM POSTS p
    WHERE p.user_id = u.id
    AND p.rating > 10)