Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
qlik4asif
Creator III
Creator III

Any wrong in below expression

Hi All,

The below expression is ok , but i am getting zero value,


=Num(Sum({<DateMonth={">=$(=Yearstart(vMaxDate_E2E_Seeds_ProductionCost))<=$(=YearEnd(vMaxDate_E2E_Seeds_ProductionCost))"}>}BUD),'##.###')


I have checked

Yearstart(vMaxDate_E2E_Seeds_ProductionCost)


YearEnd(vMaxDate_E2E_Seeds_ProductionCost)


Both are getting dates, but the whole expression is not getting value

Thanks in advance

Labels (1)
5 Replies
Anil_Babu_Samineni
MVP
MVP

Can you define the variable?

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
qlik4asif
Creator III
Creator III
Author

vMaxDate_E2E_Seeds_ProductionCost

=Max({<KPI1={'E2E Seeds Production Cost'},YTD={">0"}> + <KPI1={'E2E Seeds Production Cost'},YTD={"<0"}>}DateMonth)

Anonymous
Not applicable

Hi,

What is the format of the DateMonth field? Is it in Date format(e.g 'DD/MM/YYYY') or in MonthYear format(e.g. MM/YYYY) ?

I think it should be in Date format according to this expression to work.

Thanks,

Harshit

Anil_Babu_Samineni
MVP
MVP

If below one is working for you

Num(Sum({<DateMonth={">=$(=Yearstart(Max({<KPI1={'E2E Seeds Production Cost'},YTD={">0"}> + <KPI1={'E2E Seeds Production Cost'},YTD={"<0"}>}DateMonth)))<=$(=YearEnd(Max({<KPI1={'E2E Seeds Production Cost'},YTD={">0"}> + <KPI1={'E2E Seeds Production Cost'},YTD={"<0"}>}DateMonth)))"}>}BUD),'##.###')

Then, It should work with variables using this?

Num(Sum({<DateMonth={">=$(=Yearstart(=vMaxDate_E2E_Seeds_ProductionCost))<=$(=YearEnd(=vMaxDate_E2E_Seeds_ProductionCost))"}>}BUD),'##.###')

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
jyothish8807
Master II
Master II

Hi Asif,

Can you check if the format of DateMonth and both varibales are same ? This could be because of mis match of date format.


BR,

KC

Best Regards,
KC