Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Ok, I'm stuck with this:
I got 2 table, and I need a Result table, just as shown below:
Table Groups | ||
GroupName | StartRange | EndRange |
Bevarages | 11001 | 11007 |
Food | 21003 | 21010 |
Canned | 301117 | 301118 |
Table Items | ||
IdItem | Desc | |
11001001 | Coke | |
11001002 | 7up | |
11001003 | Absolut Vodka | |
11001004 | Duff | |
21003001 | Ruffles | |
21003002 | Pringles | |
30117005 | Beans | |
30117006 | Green Corn | |
30118001 | Souce | |
99903001 | Trim | |
Result Table | ||
IdItem | Desc | GroupName |
11001001 | Coke | Bevarages |
11001002 | 7up | Bevarages |
11001003 | Absolut Vodka | Bevarages |
11001004 | Duff | Bevarages |
21003001 | Ruffles | Food |
21003002 | Pringles | Food |
30117005 | Beans | Canned |
30117006 | Green Corn | Canned |
30118001 | Souce | Canned |
99903001 | Trim | - |
I did it with a "for..for...next...next" nested loop, but it took a life, and I have only 1mi rows.
Can anyone help me with this. I need a better way to do it.
Have you looked at IntervalMatch()?