I think my problem is pretty simple, and in SQL this would be trivial. I have two tables
TableOne = {{a, x1}, {b, x2}, {c, x3}};
TableTwo = {{a, y1}, {c, y2} , {a, y3}, {a, y4}, {b, y5}, {c,y6}, {c, y7}}
I want to abe able to join these two tables where the values of column 1 in both tables match such that:
DesiredResult = {{a, x1, a, y1}, {c, x3 , c, y2} , {a, x1, a, y3}, {a, x1, a, y4}, {b, x2, b, y5}, {c, x3, c, y6}, {c, x3, c, y7}}
I've tried with both Select[]
statements inside a Table[]
structure and also looked into JoinAcross[]
but haven't been able to acheive the desire effect. In SQL it would be simple, something like:
SELECT Col1.Table1, Col2.Table1, Col1.Table2, Col2.Table2, FROM table2 INNER JOIN table1 ON Col1.Table1 = Col1.Table2
Or something similar.