samedi 14 mars 2015

Distinct Clause not working in SQL 2005

I have so many records having duplicate taskid assigned to multiple person, but i want to show distinct records means only one taskid in output in SQL


below is my query not working give me solution



SELECT DISTINCT taskid, taskname, person, userid, dept, date, status, monitor, comments, monitor_comments, respondtime, assignedby, reassigncomment, priority,date_complete, followup_date, re_status
FROM task
WHERE (status IS NULL)

Aucun commentaire:

Enregistrer un commentaire