Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Total Across a Dimension

Hi All ,

I am using this expression to calculate TOTAL's But even though YEar is Selected in Dimension , The expression is showing TOTAL across all Years

sum(TOTAL{<Metric={'VHL'}>}Data)/1000)

Can you help me incorporating Year Dimension in the above formula

Thanks,

Sai

5 Replies
ajaykumar1
Creator III
Creator III

Try like;

sum(TOTAL{<Metric={'VHL'},year={"$(=max(year))"}>}Data)/1000)


So it might work when your selecting the year that will be the max year.


Regards,

Ajay

jonathandienst
Partner - Champion III
Partner - Champion III

Hi

It sounds like the Year field is not associated with the Metric and Data fields.In other words, there is no key between the table containing Year and the tables(s) containing the other fields. Check your table structure in the viewer (File | Table Viewer)

HTH

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
israrkhan
Specialist II
Specialist II

TRY LIKE BELOW

sum(TOTAL <YEar > {<Metric={'VHL'}>}Data)/1000

Not applicable
Author

Thanks for the response ,

But none of them is working , actually my year is coming from a Dimension Month Name

I am using a Left Function ; LEFT([Month Name],4) etc..,

How do I fit the above with Total

@jonathan dienst - All fields are in single Table

thanks,

Sai

avinashelite

Hi Sai,

Can you please share your app.