I am trying to remove duplicate rows with the following SQL:
SELECT DISTINCT r.ReqName AS "Requirement Name",
r.ReqDescription AS "Requirement Description",
r.ReqID AS "Requirement ID",
r.ReqReviewed AS "Requirement Reviewed",
r.ReqCoverageStatus AS "Requirement Coverage Status",
t.TestName AS "Test Name",
t.TestDescription AS "Test Decsription",
t.TestID AS "Test ID",
t.TestContainerName AS "Test Container Name",
r.ProjectName AS "Project Name",
t.TestCreator AS "Test Creator",
t.TestCreated AS "Test Created",
d.CurrentExecStatus AS "Current Execution Status",
t.TestTypeName AS "Test Type"
FROM RTM_V_Requirements r, RTM_V_ReqTests t, RTM_V_TestDefinitions d
WHERE r.ProjectName = 'New Hampshire Testing Project'
AND r.ProjectName = t.ProjectName
AND r.ProjectName = d.ProjectName
But I get this message:
Server: Msg 8163, Level 16, State 3, Line 1
The text, ntext, or image data type cannot be selected as DISTINCT.
How do I resolve this?
Thanx for your help.
Free Guide: Managing storage for virtual environments
Complete a brief survey to get a complimentary 70-page whitepaper featuring the best methods and solutions for your virtual environment, as well as hypervisor-specific management advice from TechTarget experts. Don’t miss out on this exclusive content!