我有两个表,我想通过公共字段Name和Color(通过合并)从Table1派生一列到Table2。
但直到我只使用一个合并的维度并且它对我来说效果很好。
现在,对于二维,它不起作用。
如果我有两张桌子:
Table1 名称:水果
|--------|--------|---------------|
| Name | Color | Rateperunit |
|--------|--------|---------------|
| banana | yellow | 3 |
|--------|--------|---------------|
| apple | red | 25 |
|--------|--------|---------------|
| apple | green | 30 |
|--------|--------|---------------|
Table2 名称:采购
|--------|---------|-------------|-----------|----------|
| Item | Color | Rateperunit | Noofitems | Totalbill|
|--------|---------|-------------|-----------|----------|
| apple | green |30 | 3 | 90 |
|--------|---------|-------------|-----------|----------|