power bi: combine multiple tables into one - powerbi

In Power BI, I am creating a report with some finance data of a company. I have 3 different tables. The table structure of all three tables are as follows:
I want to change these tables into this structure:
Is it possible to achieve this kind of structure? If yes and please suggest some method to do this?

To do it simply you can import 3 times your table using the query editor, and then in one table keep only columns for Planned, in the second table keep columns for Actual, and so on...
Hope that helps!

Related

Join 2 table in power bi

I need help on this issue as i don't have any experience in Power Bi. I want to join 2 table in Power Bi where it have the same column which is Part_Number. How can i make this 2 table to match by Part Number and return the value?
Recon Table
Inventory Table
I would like to have Part Number, Part Name, QTY, Total Quantity as the result. Hope that i can the clarification i need. Thanks a lot!
For this case you simply must merge the tables. It doesn't look like you have done a lot of research on the matter though, so it's hard to understand exactly what you need help with.
To merge your two tables in Power Query, I would right click in the left hand side menu and select Merge Queries as New.
After that you simply follow the on-screen instructions and select your two tables and their respective key columns. After merging you can choose to disable load of your two original tables to save space in your data model, but this depends on your requirements.
If this was my data model, I would think on why joining these tables are necessary, instead of using these two tables as fact tables, and creating a third table to handle the part number dimension with associated part metadata.
Read the docs: Merge queries in Power Query

new Power BI table combining unrelated data

I am trying to create a table that is a list of all possible combinations between two tables: products and companies. I'm building a dashboard in Power BI and the data comes from SQL queries. I have the following list structures for the Products table and the Companies table:
and my desired output for analysis is:
There is nothing that relates the companies to the products, and I'm trying to get a list of all of the products for each company. Can I do this in Power BI? If not, is it possible in SQL (there is nothing to join on)? Thank you for your help!
You can do this with a 'hacked' join, or a cross join. I prefer the former from a process POV, but cannot speak to speed or efficiency.
Using a Join ( Merge in PQ )
Create a new column 'DummyKey' with a value of 1 on each table.
Merge both tables using your 'DummyKey' columns.
Complete the Join process and choose the columns you want to bring through.
Cross Joins in PowerQuery according to MS
I think this 'cross join' is only technically right and does not provide future flexibility.
Both methods will get you to the same end point, and can be done in SQL or PQ.

DAX - Querying Data with DAX combine data from two tables

I am new to DAX and am pulling Tabular Data from Analysis Services. There is a lot of data and I only want to pull certain columns from different tables in the cube. I can pull a couple of columns from one table but not sure how to combine it. Please see the screenshot below any help with writing this query would be appreciated.
For example, I want to see [Region] from 'Companies' and [State] from 'Houses'
You should find the fact table related to Houses and Companies tables. Lets assume it's name is Fact, then you may use SUMMARIZE to retrieve just the combinations of the columns that exists in Fact table like follows
EVALUATE
SUMMARIZE(
'Fact',
'Houses'[State],
'Companies'[Region]
)

how to move columns in one table to other table in power bi?

I want to move(denormalize)two tables into another tabe,how can I do it?
have two tables like:- 'sales by category','product by category',
I want to move these two tables into another table which is 'products'.
i tried Related function with calucated column and it won't work bcoz those tables sharing one-one relationship
plz solve my issue who are familiar with data modelling and dax in power bi
The best way is to use the merge function in power query, follow the tutorial on the below link it'll explain it better, this will allow you to join the tables you need into query, in turn creating a table in Power BI
https://learn.microsoft.com/en-us/power-bi/desktop-shape-and-combine-data#combine-queries

Power Query - How to decode values using two tables?

How can we decode a master table like this
to decode values from codes table
to get the result like this in Power query/Power BI?
split the code table into two as Gender code and race code, and relate them to master table.
You will need to do a relationship between the master table and the coded table. But your coded table has 2 different types of data in it, gender and race. To create many to one relationships between the master table and the coded table, you probably have to split the coded table into two tables - gender and race.
Setup the relationships:
Use DAX to create new columns in the master table:
If you cannot split the coded table, then you will need to import it twice, concatenate "gender"/"race" with the code, create the relationships between master and coded 1 and coded 2 and use DAX to create the columns in master.