Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Matrix output

$
0
0

HI,

I have data something like this:

                     

IDTypeCode      value
1termterm  1
2term term 2
3Channel CHNRetail
4Channel CHNRetail90
5Drug DRGBrand
6Drug DRGGeneric

Output:

i need ALL combinations based ON market

So, a market can have many yr combinations IN a matrix 

OUTPUT ID
3,5,1
3,5,2
4,6,1
4,6,2

Please advise


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>