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: 
Anonymous
Not applicable

Current Date

Hi,

I have to calculate the sales contribution of the customers.

Am using this expression

(sum({$<DateKey={">=$(=Date(vFromDate,'YYYYMMDD'))<=$(=Date(vToDate,'YYYYMMDD'))"}, Year=, Quarter=, Month=, WeekName=, Date=, CustomerCode>} $(eSales))

- sum({$<DateKey={">=$(=Date(vFromDate,'YYYYMMDD'))<=$(=Date(vToDate,'YYYYMMDD'))"}, Year=, Quarter=, Month=, WeekName=, Date=, CustomerCode>} $(eRent)))

/

(sum(TOTAL {$<DateKey={">=$(=Date(vFromDate,'YYYYMMDD'))<=$(=Date(vToDate,'YYYYMMDD'))"}, Year=, Quarter=, Month=, WeekName=, Date=>} $(eSales))

-sum(TOTAL {$<DateKey={">=$(=Date(vFromDate,'YYYYMMDD'))<=$(=Date(vToDate,'YYYYMMDD'))"}, Year=, Quarter=, Month=, WeekName=, Date=>} $(eRent)))

This is working but i need to show current date's sales contribution without any selection.

.

Labels (1)
12 Replies
sunny_talwar
MVP
MVP

May be something like this

((Sum({$<DateKey = {"$(=Date(Today(),'YYYYMMDD'))"}, Year, Quarter, Month, WeekName, Date, CustomerCode>} $(eSales))

- Sum({$<DateKey = {"$(=Date(Today(),'YYYYMMDD'))"}, Year, Quarter, Month, WeekName, Date, CustomerCode>} $(eRent)))

/

(Sum(TOTAL {$<DateKey = {"$(=Date(Today(),'YYYYMMDD'))"}, Year, Quarter, Month, WeekName, Date>} $(eSales))

-Sum(TOTAL {$<DateKey = {"$(=Date(Today(),'YYYYMMDD'))"}, Year, Quarter, Month, WeekName, Date>} $(eRent)))) > 0.10

Anonymous
Not applicable
Author

Hi,

I have different companies, in the same dashboard we are selecting the company name. So what if company A and B has sales more than 10%.

I have created multiple alert for different companies,

I tried like this but seems like something wrong

((Sum({$<DateKey = {"$(=Date(Today(),'YYYYMMDD'))"}, Year, Quarter, Month, WeekName, Date, CustomerCode,CompanyCode={"01"}>} $(eSales))

- Sum({$<DateKey = {"$(=Date(Today(),'YYYYMMDD'))"}, Year, Quarter, Month, WeekName, Date, CustomerCode,CompanyCode={"01"}>} $(eRent)))

/

(Sum(TOTAL {$<DateKey = {"$(=Date(Today(),'YYYYMMDD'))"}, Year, Quarter, Month, WeekName, Date,CompanyCode={"01"}>} $(eSales))

-Sum(TOTAL {$<DateKey = {"$(=Date(Today(),'YYYYMMDD'))"}, Year, Quarter, Month, WeekName, Date,CompanyCode={"01"}>} $(eRent))))>0.10

sunny_talwar
MVP
MVP

how about a chart where it highlights the company if the ratio is above 0.10?