Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
cable_si
Starting Member
20 Posts |
Posted - 2011-03-07 : 10:59:24
|
Hi AllI am trying to run the below query on the below tableSelect distinct recid, surname,forename, yr_reg from mytableForename RecID Surname Yr_Regelmer 20 fudd Simon 8 0 Parry 1Home 17 0 Simpson Phil 120936 0 Little Janet 117927 0 Robinson elmer 20 0 fudd Simon 8 0 Parry 1Home 17 0 Simpson however when i run my query my results are not distinct, the only person who displays as distinct is Simon Parry, im sure its something to do with the yr_reg column having blank/null valuesthe output of the query isrecid surname forename yr_reg117927 RobinsonJanet 120936 Little Phil 17 Simpson Home 17 Simpson Home 20 fudd elmer 20 fudd elmer 8 Parry Simon 1Can anyone advise how i could get a distinct list or why its not working correctlythanks in advancecable |
|
|
|
|