Exclude Duplicate Rows (Visual Database Tools)
Applies to: SQL Server
If you want to see only unique values in a result set, you can specify that you want to exclude duplicates from the result set.
To exclude duplicate rows from the result set
Right-click the background of the Diagram pane, then choose Properties from the shortcut menu.
In the Property window, click Distinct values and set the value to Yes.
The Query and View Designer inserts the keyword DISTINCT in front of the list of display columns in the SQL statement.
Note
If you use the DISTINCT keyword you may not be able to modify the result set in the results pane.
See Also
Specify Search Criteria (Visual Database Tools)
Sort and Group Query Results (Visual Database Tools)
Phản hồi
https://aka.ms/ContentUserFeedback.
Sắp ra mắt: Trong năm 2024, chúng tôi sẽ dần gỡ bỏ Sự cố với GitHub dưới dạng cơ chế phản hồi cho nội dung và thay thế bằng hệ thống phản hồi mới. Để biết thêm thông tin, hãy xem:Gửi và xem ý kiến phản hồi dành cho