views:

112

answers:

1

Can you do more than one clause in SQL without using aggregation and only: selection, join? Thanks.

+1  A: 

If you mean having multiple WHERE's (ands), then yes.

SELECT user.id, post.title
  FROM user LEFT JOIN post ON (post.user = user.id)
  WHERE (post.title LIKE '%Monkeys%')
    AND (user.id > 3)
    AND (user.id < 20)
Jonathan Sampson