Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
7 years ago
Solved

Double filtering?

Hello All,

 

I just recently started workign with Power BI/DAX. Via tee help of internet I create below:

Budget Cur_Month Cur_Year =
CALCULATE(
[Budget];
FILTER(
'sales InvoiceItems';RELATED(
'sales Time'[Cal_Year]
) = [calc Cur_Year] && RELATED(
'sales Time'[Month_No]
) = [calc Cur_Month]
)
)
which should give me the budget for a month, but I need to incorperate another filter/parameter from the below table:
 
Can you please give me a hint?
 
  • Hi Anonymous 

    If your tables have relationships as below:

     

    Create a measure in sales InvoiceItems

    measure_budget = SUM('sales InvoiceItems'[budget]) 

    Add this measure in the matrix viusal ad below, along with "year" and "month" columns from "sales Time" table.

    Best Regards
    Maggie

     

    Community Support Team _ Maggie Li
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

2 Replies

  • v-juanli-msft's avatar
    v-juanli-msft
    Icon for Community Support rankCommunity Support

    Hi Anonymous 

    If your tables have relationships as below:

     

    Create a measure in sales InvoiceItems

    measure_budget = SUM('sales InvoiceItems'[budget]) 

    Add this measure in the matrix viusal ad below, along with "year" and "month" columns from "sales Time" table.

    Best Regards
    Maggie

     

    Community Support Team _ Maggie Li
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hello Maggie, 

       

      I will give it a try ans let you know the result