Forum Discussion

muthusaran's avatar
muthusaran
Regular Visitor
2 years ago

MS Excel Pivot to Power BI

I'm new to Power BI and while learning it, I tried to replacate few existing Microsoft Excel Pivot in PowerBI and succeeded. One of the attached Pivot couldn't be replicated in PowerBI. Please help me with it .

You may give suggestions like after importing the data (this data exists in SQL server), Create Matrix --> Add Rows (fields names) --> Add columns (field names) --> Add Values (field names) for me to try it out. Sample data that I used and corrsponding Pivot is attached here

 

Data : (Can be in Excel or SQL table) Imported into PowerBI

YearMonthProductBatchCGUnitMonthProd CostPacking CostCover CostMRPProfitExpense
202305BritanniaP01Chennai0120230110111530
202305BritanniaP01Chennai01202302910.51000.5
202305BritanniaP01Chennai02202302100.51.51640.5
202305BritanniaP01Chennai03202302110.51.51651
202305BritanniaP01Chennai0420230290.51.51321
202305BritanniaP01Chennai01202303910.51000.5
202305BritanniaP01Chennai02202303100.51.51640.5
202305BritanniaP01Chennai03202303110.51.51651
202305BritanniaP01Chennai0520230390.51.51321
202305BritanniaP01Chennai01202304910.51000.5
202305BritanniaP01Chennai05202304100.51.51640.5
202305BritanniaP01Chennai01202306910.51000.5
202305BritanniaP01Chennai05202306100.51.51640.5
202305BritanniaP02Chennai0120230110111530
202305BritanniaP02Chennai01202302910.51000.5
202305BritanniaP02Chennai02202302100.51.51640.5
202305BritanniaP02Chennai03202302110.51.51651
202305BritanniaP03Chennai0420230290.51.51321
202305BritanniaP03Chennai01202303910.51000.5
202305BritanniaP03Chennai02202303100.51.51640.5
202305BritanniaP04Chennai03202303110.51.51651
202305BritanniaP04Chennai0520230390.51.51321
202305BritanniaP04Chennai01202304910.51000.5
202305BritanniaP04Chennai05202304100.51.51640.5
202305BritanniaP04Chennai01202306910.51000.5
202305BritanniaP04Chennai05202306100.51.51640.5

 

MS Excel Pivot settings are:

Excel Pivot coming out as

 

MS Excel Pivot looks like below. For each type of cost, it shows different cost involved per month.

 

However, If I replicate in PowerBI, i'm seeing like below. Under each Unit, types of amt is listed instead of Types of Amount as above (getting in excel). I need to get same as Excel pivot in Power BI. Please help me the options/suggestions to achieve.

 

 

 

2 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi muthusaran ,

    Please refer to my pbix file to see if it helps you.

     

    Please learn more about matrix in power bi: Create a matrix visual in Power BI - Power BI | Microsoft Learn

     

    How to Get Your Question Answered Quickly 

     

    If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .

     

    Best Regards
    Community Support Team _ Rongtie

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • muthusaran's avatar
      muthusaran
      Regular Visitor

      Thanks for the effort.

       

      I need this similar to Excel pivot.

      If we have future period, it will keep on appending and we need to drag to right side which is not expected.

      Expected Matrix/Table in Power BI: (Same as Excel Pivot below)

       

        

      Below is the Pivot in Excel looks.

       

      PBIX File: I don't see an option to upload. But, my PBIX looks like below

       

       

      But, My visualization in my pbix is like below