Hello, I don't know how to do Cartesian join that needs to be based on the cell value. Following are the three tables:
Table 1
A B
--------
1 a
2 a
3 b
4 c
5 d
... (and so on)
Table 2
B value
------------
a 12
b 15
c 20
d 100
Table 3
B C value
------------------
a a1 111
a b1 222
a c1 333
b a6 193
b b7 278
c c4 323
c c5 567
d d1 444
Here are the results I need will be as follows:
A B C
----------------
1 12 111
1 12 222
1 12 333
2 12 111
2 12 222
2 12 333
3 15 193
3 15 278
4 20 323
4 20 567
5 100 444
What it happens is that table 1 of B is the foreign key of table 2 of B. So, whatever value is used in table 1 will get the corresponding value in table 2. As per table 1 of C, it will depend the value that is selected for the column B and then find all the corresponding combinations. Is there a simple way it can create all the combination?
Thank you so much
Bookmarks