How to get one unique record from the same list of records from table? No Unique constraint in the table

后端 未结 2 1709
花落未央
花落未央 2021-01-16 16:19

I have one query in SQL Server output,

Suppose i have one table (Ex.StudentMaster) having some fields-No unique constraints. For Ex. RollNumber and Name The table h

2条回答
  •  -上瘾入骨i
    2021-01-16 17:04

    You can use DISTINCT which return's distinct combination's of columns.

    SELECT DISTINCT RollNo, Name
    FROM mytable
    

提交回复
热议问题