What is the difference between distinct clause and group by
clause?
Answers were Sorted based on User's Feedback
Answer / swamy
Distinct Clause:
---------------
Distinct Clause Will Eliminate the Duplicate data or Rows
when u r selecting from table .So it Produce the Data or
Rows with out Duplication.Generally Distinct Clause will
be Placed on the Column of the Table.
Group Clause:
-------------
Group Clause will group or pack the rows or data based on
the Column(S).
| Is This Answer Correct ? | 24 Yes | 5 No |
Answer / rkvenky
distinct suppress the duplicates of data in the select stmt.
where as group by combines the data which we willgive in
order.
2.group by used at the end of select stmt
distint used in select stmt to columns
3.
group by is function where distinct is keyword
| Is This Answer Correct ? | 8 Yes | 13 No |
Explain different types of locks in sql server.
What are the different Topologies in which Replication can be configured?
What is optimization and its types?
What is index fragmentation in ms sql server?
How to apply cascading referential integrity in place of triggers?
If we use where clause in the left outer join then how the query would behave/act?
What is Covering Indexes? Plz explain with example
Other than truncate statement, which other command can by-pass the trigger on the tables?
What happens if ntwdblib.dll is missing on your machine?
What is a sub-query? When would you use one?
What is RAID and what are different types of RAID configurations?
UPDATE statement can on a single table or on the multiple table?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)