Forum Discussion

Flashed's avatar
Flashed
Frequent Visitor
8 years ago
Solved

How to filter No Range

Hello Guys,

 

I'm trying to develop a report. I'am using a query from out Dynamics NAV. 

This gives me the follwing information:

 

GL Account No and Amount. I want to do the following. I want to the amount specified by a range of GL Accounts No.

 

I want to create a measure.

I've tried the following: 

 

Recurring Rev = 
Calculate(Sum(RecREV[Amount]);Filter(RecREV[GL AccountNo] >= "8000" .. "8089")

Or

Calculate(Sum(RecREV[Amount]);Filter(RecREV[GL AccountNo] >= "8000" & <= "8089")

 

Using multiple filters is way to much work if I want to make a very specified range.

 

I hope you guys can help me out!

 

 

  • Flashed

     

    Hi, GL AccountNo is a text field?

     

    If is a number field you can try with:

     

    M =
    CALCULATE (
        SUM ( RecREV[Amount] );
        FILTER ( RecREV; RecREV[GL AccountNo] >= 8000 && RecREV[GL AccountNo] <= 8089 )
    )

    Regards

     

    Victor

    Lima - Peru

2 Replies

  • Vvelarde's avatar
    Vvelarde
    Community Champion

    Flashed

     

    Hi, GL AccountNo is a text field?

     

    If is a number field you can try with:

     

    M =
    CALCULATE (
        SUM ( RecREV[Amount] );
        FILTER ( RecREV; RecREV[GL AccountNo] >= 8000 && RecREV[GL AccountNo] <= 8089 )
    )

    Regards

     

    Victor

    Lima - Peru

  • Hi,

     

    Try this

     

    =CALCULATE(SUM(RecREV[Amount]);RecREV[GL AccountNo] >= 8000;RecREV[GL AccountNo] <= 8089)

     

    Hope this helps.