Forum Discussion

vickyArce's avatar
vickyArce
Frequent Visitor
7 years ago
Solved

Create a relation with a intermediate column name

Hi,

 

I have a table, with some formating(Groupby and Transpose) in power query, I lost the column that I need to create a relationship with, so the cross filtering is not working on the new formatted table.

 

Is there a way to create a relation with a intermediate column name? Or another solution?

 

Or maybe there is a way to do the group by and pivot on a visual instead of doing it in power query?

 

Thank you

  • Thank you for your reply, finally I found a way to do it in Matrix, and it worked out perfectly.

3 Replies

  • vickyArce's avatar
    vickyArce
    Frequent Visitor

    The original table:

    FurnaceNumberSumEntrantSumEntrantDRISumEntrantScrapSumEntrantAlloysSumModifiant
    B1165.6114.70.010384.0-6.1
    A2181.183.70.010954.30.1
    A3175.681.00.010133.30.1
    B4171.965.10.12569.50.1
    A5179.0140.20.01561.01.6
    B6184.3134.10.07449.01.5
    A7180.2127.90.09721.01.5
    A8180.7129.10.010573.01.5
    A9171.0115.70.011560.01.4
    B10180.4129.50.010092.01.5
    B11173.4117.90.010602.01.4

     I needed to group by the Furnace label, and summarize all the columns, and then pivot the table to this format:

    FurnaceAB
    SumEntrant  
    SumEntrantDRI  
    SumEntrantScrap  
    SumEntrantAlloys  
    SumModifiant  

     

    I was able to do all those formattings in power query, but the problem is at the end, I lost my Number column, on which I use the crossing filtering  through table relationships.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi vickyArce ,

      You can duplicate a query table and do unpivot column on it(keep furnace and types), then use this table as bridge to link two tables.(furnace to original furnace field, furnace type to furnace table)

      Unpivot columns (Power Query)

      Regards,
      Xiaoxin Sheng

  • vickyArce's avatar
    vickyArce
    Frequent Visitor

    Thank you for your reply, finally I found a way to do it in Matrix, and it worked out perfectly.