In performance wise distinct is good or group by is good?
eg:select name from emp group by name;
select distinct name from emp;
Answer Posted / anil sharma
Group apply before where clause and distinct apply after
where clause.
So group by is good.
| Is This Answer Correct ? | 4 Yes | 10 No |
Post New Answer View All Answers
How to get a list of columns in a view using the "sp_help" stored procedure?
What are cascading parameters in ssrs reports?
What kind of problems occurs if we do not implement proper locking strategy?
What is normalization of database?
what is a sub-report?
How can you list all the table constraints in a database?
Explain multiserver query
Explain table valued parameters in sql server? Why tvp used?
Can you explain what are the restrictions applicable while creating views? : SQL Server Architecture
What is the advantage of sql server?
While migrating Microsoft SQL Server 2008 database to SQL Azure, what can be done to ensure the database connectivity does not degrade?
What is the new security features added in sql server 2014? : sql server security
Explain transaction server consistency?
Can you roll back the ddl statement in a trigger?
What is ssrs?