Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

showing latest value in textbox

AOA

I hava a bar chart showing month wise inventory in stock....

say

jan 186799

feb 195335

mar 20227

apr  25354

now i want to shw a current month inventory in text box.... which is APR where MONTH is dimension name....

and expression is =sum({<stock-={0}>}bal_amount)

kinldy advice:

4 Replies
sivarajs
Specialist II
Specialist II

use this expression

sum({<Month_No={"$(=max(Month_No))"}>}Amt)

Month_No you can get using following expression else you can use month also

date(Date#(Date,'DD-MMM-YYYY'),'MM')

Not applicable
Author

try this

sum({<month={"$(=max(date(month,'MMM')))"}>}Amt)

er_mohit
Master II
Master II

sum({<Month={$(=month(today()))}>}bal_amount)

Not applicable
Author

jan 186799

feb 195335

mar 20227

apr  25354

thnks to all of you who replied unfortunatly my month dimension is not a date function

its hardcoded table

time id month year

1            jan     2013

2            feb     2013

3           mar    2013

4           apr       2013

i have reload the data on 31 apr so APRIL become the latest month.

i also have a field of max_month which  giving current month i.e APR

my query is (select sum(bal_amt) where month=max_max_month) in text box

so all your replies are not working because no date involve in my sheet..

and also i dont want maximum value of amount to display i want latest

mean (max_month) value.. which is 25354

thnks

if u guys can help