Wednesday, May 09, 2012 12:26 PM
if i am excuting the sp the same row displays multiple times.. there is no duplicate records ..
how can i do this?
Wednesday, May 09, 2012 12:28 PMAnswererPlease post sample data + desired result
Best Regards, Uri Dimant SQL Server MVP http://dimantdatabasesolutions.blogspot.com/ http://sqlblog.com/blogs/uri_dimant/
Thursday, May 10, 2012 2:42 AMModerator
DISTINCT: Specifies that COUNT returns the number of unique nonnull values. You could use DISTINCT in your T-SQL sentences.
DISTINCT is an optional keyword that precedes the list of columns specified in the SELECT clause. The DISTINCT keyword asks your database system to evaluate the values of all the columns as a single unit on a row-by-row basis and eliminate any redundant rows it finds.
Please remember to mark the replies as answers if they help and unmark them if they provide no help. This can be beneficial to other community members reading the thread.
- Marked As Answer by Maggie LuoMicrosoft Contingent Staff, Moderator Thursday, May 17, 2012 8:53 AM