What is the difference between GROUP BY and ORDER BY in
Sql?
Answer Posted / haritharavi
Order by clause is used to sort the rows in ascending or
descending order.Group by clause is used to sort/group a
number of rows together so as to apply aggregate functions.
So order by is only to sort the records where as group by
is to sort and find aggregate functions of each group.
Is This Answer Correct ? | 32 Yes | 5 No |
Post New Answer View All Answers
Please can the SQL code below be interpreted IF @xMatchCriteria='MATCH12' BEGIN IF EXISTS (Select * from #InsightData where (EmailAddress=@xDCPEmailAddress ) ) BEGIN SET @xTestMatchCriteria = @xMatchCriteria; SELECT @xCRMCustomerId=CustomerId, @xCRMDcpCustomerId=DcpCustomerId, @xCRMPortalCustomerID=PortalCustomerID,@xCRMDcpID=DcpID, @xCRMCardNumber=CardNumber, @xCRMEmailAddress=EmailAddress, @xCRMfirtLetterFirstName=firtLetterFirstName, @xCRMLastName=Surname,@xCRMAddressLine1=AddressLine1, @xCRMPostCode=PostCode FROM #InsightData where (EmailAddress=@xDCPEmailAddress ) END ELSE BEGIN SET @xTestMatchCriteria='No'+@xMatchCriteria; END END
Is the syntax correct? Explain the meaning of the syntax given below: $dbc = mysqli_connect('data.aliensabductedme.com', 'owen', 'aliensrool', 'aliendatabase');
What are date and time data types in mysql?
What is mysql database used for?
Is mariadb faster than mysql?
How to include numeric values in sql statements?
How do I run mysql on a mac?
What is clob in mysql
How do I edit a table in mysql workbench?
How to delete a database from mysql server.
SQL is not case sensitive. DELETE is the same as delete. State Whether True or False?
How to convert character strings to dates?
Where is mysql used?
What is the use of concat() in mysql?
How to set mysql variable in php?