Welcome Guest. Sign in or Signup

2 Answers

Having vs Where Clause

Asked by: 2984 views SQL

What are the differences between having and where clause. Where is each one used?

Related Questions

2 Answers



  1. PANDU CRAZY on Feb 18, 2012 Reply

    SELECT BUSINESS_UNIT,COUNT(*) FROM PS_PO_HDR GROUP BY BUSINESS_UNIT HAVING COUNT(*) < 10; This is HAVING criteria. HAVING is used to perform an action on groups created by GROUP BY similar to that of the WHERE clause on rows in a basic SQL statement. The WHERE clause limits the rows evaluated. The HAVING clause limits the grouped rows returned.

    +4 Votes Thumb up 0 Votes Thumb down 0 Votes



  2. candidate on May 12, 2012 Reply

    Pandu has the right answer!

    0 Votes Thumb up 0 Votes Thumb down 0 Votes


Answer Question