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 |
|
jpizzolato
Starting Member
1 Post |
Posted - 2008-03-25 : 12:31:05
|
| I have a table that is created based on a heirarch of set criteria and need to number the subsets within. The best way to illustrate what I want to accomplish is through an example.Rank | Item_1 | Item_2 | Class---- | ------ | ------ | ------1 | 1A | 1B | ExactMatch2 | 1A | 1C | Sub3 | 1A | 1D | Sub1 | 2B | 2F | ExactMatch2 | 2B | 2G | SubIs there a way to accomplish this? Any help or suggestions are appreciated.I apologize for the formatting, but I think you should be able to get the point.thanks, |
|
|
TG
Master Smack Fu Yak Hacker
6065 Posts |
Posted - 2008-03-25 : 12:39:45
|
| Ok - that's the desired result, what is the starting point look like?Be One with the OptimizerTG |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-03-25 : 14:25:36
|
| How do you want to rank them? on what basis? Please explain with help of some sample data |
 |
|
|
LoztInSpace
Aged Yak Warrior
940 Posts |
Posted - 2008-03-25 : 19:31:18
|
| Check out the RANK/DENSE RANK functions |
 |
|
|
|
|
|