Frage im Vorstellungsgespräch bei eClinicalWorks

What is the difference between having and where clause in SQL? What is Indexing in SQL?

Antwort im Vorstellungsgespräch

Anonym

22. Okt. 2017

1) The WHERE clause is used to filer rows from a results. For instance SELECT COUNT(SalesOrderID) FROM Sales.SalesOrderDetail 2) The HAVING clause is used to filter values in a GROUP BY. You can use them to filter out groups such as SELECT SalesOrderID, SUM(UnitPrice * OrderQty) AS TotalPrice FROM Sales.SalesOrderDetail GROUP BY SalesOrderID HAVING SalesOrderID > 50000

2