Forum Discussion

OzgurKlc's avatar
OzgurKlc
Frequent Visitor
3 years ago

Wrong sub totals and same row

Hi All,

 

I have problem with subtotal of matrix report.

 

My measure is like below but in the report I am getting like this. Same row number and wrong sub totals  with customer name.

Thx for your assist

 

2005 = SUMX(VALUES('Order'[PArtno]),
                SUMX(
                FILTER(
                    RELATEDTABLE('BOM'),
                        ('BOM'[Whs]<>"MSSL"
                          &&
                          'BOM'[whs2]="2005")
                          &&
                          (
                                RIGHT('BOM'[SubParts],3)="IS1"||
                                RIGHT('BOM'[SubParts],3)="IS2"||
                       
                                RIGHT('BOM'[SubParts],3)="IS3"
                             
                          )
                ),
                ('Bom'[Qty] * 'Bom'[Weight])/1000
                )
           
            * [rate]
            )

5 Replies

  • OzgurKlc's avatar
    OzgurKlc
    Frequent Visitor

    Hi Greg_Deckler  ,

    It is working well when I remove the company name ( it is in order table with part code) measure from the rows . any suggest?

    • Greg_Deckler's avatar
      Greg_Deckler
      Icon for Community Champion rankCommunity Champion

      OzgurKlc Well, that would also suggest a potential missing relationship. What does the data model look like?

      • OzgurKlc's avatar
        OzgurKlc
        Frequent Visitor

          order table and bom table  have many to many and btw bom and stock balance(qty) have many to many.

  • Hi,

    Share some data to work with and clearly show the expected result.