Forum Discussion

abc_777's avatar
abc_777
Solution Specialist
2 years ago
Solved

hi

hi

 

i have a single table  when i filter by

 

dont starts with CR

only invoice date 01-01-2024 to 01-01-2024 (one day)

 and net_amt >= 4000 then i see in power bi table or data menu tab which is on second on left side 165 data and this 165 is same with mssql query 

 

but by  using measure formula

 

CALCULATE (
    COUNT('bm_retail_t ssummary'[INVOICE_NO]),
    FILTER (
        VALUES ( 'bm_retail_t ssummary'[INVOICE_NO] ),
        NOT ( LEFT ( 'bm_retail_t ssummary'[INVOICE_NO], 2 ) = "CR" )
            && CALCULATE (
                SUM ( 'bm_retail_t ssummary'[NET_AMT] ),
                ALLEXCEPT (
                    'bm_retail_t ssummary',
                    'bm_retail_t ssummary'[INVOICE_NO],
                    'bm_retail_t ssummary'[STORE_CODE]
                )
            ) >= 4000
    )
)
 
in power bi visual i see 621 in total .
 

can some one help me out as this is same table and there are no relation with other table in measure calculaiton

 i want to have 165 output from single table measure formaula count of invoice number 

 

  there are few blank which are less than 4000 and this is fine. dont worrry about followings

 


 

thanks

 

  • need calcuative column not measure. thx i solved it myself

1 Reply

  • abc_777's avatar
    abc_777
    Solution Specialist

    need calcuative column not measure. thx i solved it myself