This is my select statement:
SELECT lastName + ',' + firstName as Name,
classNumber
FROM STUDENT
RIGHT JOIN ENROLL ON Enroll.stuid = Student.stuid
and the output:
name classnumber
--------------------------
Smith,Tom ART103A
Smith,Tom HST205A
Chin,Ann ART103A
Chin,Ann CSC201A
Chin,Ann MTH103A
McCarthy,Owen ART103A
McCarthy,Owen MTH103C
Rivera,Jane CSC201A
Rivera,Jane MTH101B
I would like it so that each name only appears in the first column once. Any help or idea greatly appreciated.