Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Champion III
Champion III

RE:Overall count

Hi all,

What wrng in my expression? in stright table.

Metric: distinc pass&fail for exec testid

and also apply modified date on  condition to view he latest record.

=Count(

if(

Aggr

(

DISTINCT

(

max({<Exec_Status={'Passed','Failed'}>}Exec_ModifiedOn),

lvl_id,Period,Exec_TestID

)

=Exec_ModifiedOn

,Exec_TestID

))

)

19 Replies
Highlighted
MVP & Luminary
MVP & Luminary

HI,

I am not sure what you are try to do with the expression, there are lot of syntax errors. = at the end of the expression,

Try this expression

=Count({<Exec_Status={'Passed','Failed'}>} Aggr(

max({<Exec_Status={'Passed','Failed'}>}Exec_ModifiedOn),

,lvl_id,Period

,Exec_TestID

))

If not working attach sample data and your expected output.

Regards,

Jagan.

Highlighted

Not really sure what the output requirement is but may be If needs to go within the Aggr?

May be this:

=Count(Aggr(DISTINCT If(Max({<Exec_Status={'Passed','Failed'}>}Exec_ModifiedOn) = Exec_ModifiedOn, Exec_TestID), lvl_id,Period, Exec_TestID))



Highlighted
Champion III
Champion III

my req is .... whenevr am selecing any filer  in status  ...it is gvng the exact count ....

meanwhile  i hve clear all selections it is nt gvng exact count.

Highlighted

For each row you are not getting the correct count or the overall count at the top(or bottom) is getting calculated incorrectly?

Highlighted
Champion III
Champion III

and  this exp

=Count(Aggr(DISTINCT If(Max({<Exec_Status={'Passed','Failed'}

and not IsNull(Exec_TestID)>}Exec_ModifiedOn)

= Exec_ModifiedOn, Exec_TestID), lvl_id,Period, Exec_TestID))

in exec_test id  i hve nul id means some data hvng no id.  how can i use exp with isnull?

Highlighted
MVP & Luminary
MVP & Luminary

Hi,

If you attach sample data/file and your expected output then it is easier to give solution.  Otherwise it is very difficult.

Not sure what dimensions are you using, datamodel etc.

Regards,

Jagan.

Highlighted
Champion III
Champion III

in  each row getting correct values.....top total values are nt getting correct

Highlighted

Try this:

=Count(Aggr(DISTINCT If(Max({<Exec_Status={'Passed','Failed'}, Exec_TestID = {"=Len(Trim(Exec_TestID)) > 0"}>} Exec_ModifiedOn) = Exec_ModifiedOn, Exec_TestID), lvl_id,Period, Exec_TestID))

or

=Count(Aggr(DISTINCT If(Max({<Exec_Status={'Passed','Failed'}, Exec_TestID = {"=IsNull(Exec_TestID)) = 0"}>} Exec_ModifiedOn) = Exec_ModifiedOn, Exec_TestID), lvl_id,Period, Exec_TestID))

Highlighted
Champion III
Champion III

dimensions:

lvl id


period