21 December 2011

SQL HAVING Clause

SQL HAVING Clause

The HAVING clause was added to SQL because the WHERE keyword could not be used with aggregate functions.

for example:

SELECT Customer,SUM(OrderPrice) FROM Orders
GROUP BY Customer
HAVING SUM(OrderPrice)<2000


No comments:

Post a Comment

Comments Welcome

Find number of letter occurence of all letter in c#

  Find number of letter occurence of all letter in c#  namespace ConsoleApp1 {     internal class Program     {         static void Main(st...