sql server - SQL select distinct by 2 or more columns -
i have table lot of columns , need write select
take unique values. main problem need check 3 columns @ same time , if 3 columns have same values in columns(not between them, in own column) distinct
. idea should distinct(column1 , column2 , column3)
any ideas? or need more information, because i'm not sure if gets have in mind.
this example. select should return 2 rows this, 1 last column have yes , other row with
no`.
this distinct
keyword for:
select distinct col1, col2, col3 mytable
Comments
Post a Comment