I am going to appologise in advance for how this question may come out but i will try and explain my best.
I have managed to produce a result set into a temp table which looks like the below.
col1 col2 col3 col4 col5
1 1 1 1 0
1 1 1 0 1
2 2 2 2 0
2 2 2 0 2
So in effect i would like col4 and col5 to read
col4 col5
1 1
2 2
as i am using sql 2005 i am unable to use a merge.
Please can someone advise what function would be best to use to get my desired out come.
Thank you in advance
Aucun commentaire:
Enregistrer un commentaire