Hi everyone,
What Im trying to do is not display duplicate color records in the pcol1 column, heres my sql string and the results are shown below that. The pcol1 column contains the 2 b/green 3 red and 2 navy records.
Thanks In advance
Shaun
select pc1.id, pc1.colorid, pcolid = (select [id] from colorcanvass where [id] = color1), pcolpic1 = (select colorpic from colorcanvass where [id] = color1), pcol1 = (select colorname from colorcanvass where [id] = color1), pcol2 = (select colorname from colorcanvass where [id] = color2) from productcolors pc1 join colorcombo CB on (CB.id = pc1.colorid) where pc1.prodid = 102
134 4 14 IMAGES/pallete/canvas A/h15_bgreen.gif b/green nothing
135 22 14 IMAGES/pallete/canvas A/h15_bgreen.gif b/green white
136 3 4 IMAGES/pallete/canvas A/h4_red.gif red nothing
137 26 4 IMAGES/pallete/canvas A/h4_red.gif red white
138 35 4 IMAGES/pallete/canvas A/h4_red.gif red yellow
139 25 18 IMAGES/pallete/canvas A/h19_navy.gif navy white
140 34 18 IMAGES/pallete/canvas A/h19_navy.gif navy l/grey
What Im trying to do is not display duplicate color records in the pcol1 column, heres my sql string and the results are shown below that. The pcol1 column contains the 2 b/green 3 red and 2 navy records.
Thanks In advance
Shaun
select pc1.id, pc1.colorid, pcolid = (select [id] from colorcanvass where [id] = color1), pcolpic1 = (select colorpic from colorcanvass where [id] = color1), pcol1 = (select colorname from colorcanvass where [id] = color1), pcol2 = (select colorname from colorcanvass where [id] = color2) from productcolors pc1 join colorcombo CB on (CB.id = pc1.colorid) where pc1.prodid = 102
134 4 14 IMAGES/pallete/canvas A/h15_bgreen.gif b/green nothing
135 22 14 IMAGES/pallete/canvas A/h15_bgreen.gif b/green white
136 3 4 IMAGES/pallete/canvas A/h4_red.gif red nothing
137 26 4 IMAGES/pallete/canvas A/h4_red.gif red white
138 35 4 IMAGES/pallete/canvas A/h4_red.gif red yellow
139 25 18 IMAGES/pallete/canvas A/h19_navy.gif navy white
140 34 18 IMAGES/pallete/canvas A/h19_navy.gif navy l/grey