Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

ravitpost
New Contributor II

Total for variable

Hi

I have expression in table called 'vPass' that return result 0 or 1.

The vPass value is varible called 'vCalTrueFalse':

vPass =$(vCalTrueFalse).

I need to create total field for vPass in TextObject at dashboard.

I tried ' Sum($(=vCalTrueFalse))' but it give me an error: 'Nested aggregation not allowed'.

How can I do it?

Thanks!

26 Replies
stabben23
Honored Contributor

Re: Total for variable

Hi Ravit,

And how does you Variable vCalTrueFalse looks like, is it a aggregation?

ravitpost
New Contributor II

Re: Total for variable

vCalTrueFalse = if($(vCalPassFail)='Pass', 1,0)

vCalPassFail =

if

((ParamID =98 or ParamID=99) and  $(vResult)<vMCS,'Fail',

if

((ParamID =102 or ParamID=100) and TestnameID<3 and $(vResult)<vGoodput, 'Fail',

if

(DashboardID =1 and $(vResult)<Connectivity, 'Fail',

if

(DashboardID =5 and $(vResult)<TotalSamplingTime, 'Fail',

if

((ParamID =102 or ParamID=100) and TestnameID>2 and $(vResult)<vGoodput_FDX, 'Fail','Pass')))))

sdmech81
Valued Contributor

Re: Total for variable

Hi,

Plss attach sample..

ravitpost
New Contributor II

Re: Total for variable

Pass.PNG

Pass column represent variable vCalPassFail

vPass column represent variable vTrueFalse

What I need to do is show in text object the 'Pass' percentage.

vinieme12
Esteemed Contributor II

Re: Total for variable

Try

Sum( AGGR( SUM($(=vCalTrueFalse)) , YourTableDimensions))


or post the app

ravitpost
New Contributor II

Re: Total for variable

Its return zero.

How can I post the app?

Partner
Partner

Re: Total for variable

Hi Ravit,

If possible could you please attach a sample file?

Because normally I think =sum(vCalTrueFalse)   is enough.

Thanks.

Aiolos Zhao

ravitpost
New Contributor II

Re: Total for variable

I cannot attached the file (security issue).

Any way, its still return zero.

See attach table and Grade, is there another way to calculate grade?

Pass.PNG

vinieme12
Esteemed Contributor II

Re: Total for variable

see this post on attaching a file

Uploading a Sample