Forum Discussion
Anonymous_KH
3 years agoFrequent Visitor
Using DAX How to Create a new table from existing tables
Hello Power BI community,
A very simple question on creating a new table in Power BI.
Please find below as a data
Table 1
| CANDY | OFFICE |
|--------|------------|
| Nomi | Challakere |
| Sinnu | Durga |
| Toli | Shimoga |
| Naky | Loli |
| Toli | Burgi |
Table 2
| OFFICE | PRODUCER ID |
|------------|-------------|
| Challakere | 1 |
| Durga | 2 |
| Shimoga | 3 |
| Loli | 4 |
| Burgi | 5 |
So i want New table with Column (candy) from table 1 and (Producer id ) from table 2
Try:
Table 3 = SELECTCOLUMNS ( 'Table 1', "Candy", 'Table 1'[CANDY], "Producer", LOOKUPVALUE ( 'Table 2'[PRODUCER ID], 'Table 2'[OFFICE], 'Table 1'[OFFICE] ) )
3 Replies
- sudhavHelper V
you can use merge queries as nwe and select required colmns in PQE. otherwise use joins in DAX
- Anonymous_KHFrequent Visitor
Can You Please Write Down DAX Function here
- PaulDBrownCommunity Champion
Try:
Table 3 = SELECTCOLUMNS ( 'Table 1', "Candy", 'Table 1'[CANDY], "Producer", LOOKUPVALUE ( 'Table 2'[PRODUCER ID], 'Table 2'[OFFICE], 'Table 1'[OFFICE] ) )