Qlik Community

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Guage, expression, two tables!

Please can someone help me with the attached example.

I have two tables on the attached:

CONCERNS and TRANSACTIONS.

I would like to create TWO guages - one for the current month and one for the previous

month which show the percentage of concerns.

To work out the no of the concerns I need to do a count on concernID

To work out the transcations do a count on the pick column where it is '1'

So for example - current month

needs to be count of concernID / Count of Pick * 100 BUT only for the current month ?

can someone help me achieve this?

I also do not want to fix it so that I can select on plant that only appears in the transactions table !!

Thank you

1 Solution

Accepted Solutions
balrajahlawat
Champion
Champion

try like this:

CurrentMonth:

=(Count({<MonthField=,Year=,MonthField={'$(=max(month(DateField)))'}>} concernID )

/

Count({<MonthField=,Year=,MonthField={'$(=max(month(DateField)))'}, PickField={'1'}>} concernID or PickID))*100


Previous Month:


=(Count({<MonthField=,Year=,MonthField={'$(=max(month(DateField))-1)'}>} concernID )

/

Count({<MonthField=,Year=,MonthField={'$(=max(month(DateField))-1)'}, PickField={'1'}>} concernID or PickID))*100

View solution in original post

5 Replies
balrajahlawat
Champion
Champion

their is only one table which is Concern only

balrajahlawat
Champion
Champion

try like this:

CurrentMonth:

=(Count({<MonthField=,Year=,MonthField={'$(=max(month(DateField)))'}>} concernID )

/

Count({<MonthField=,Year=,MonthField={'$(=max(month(DateField)))'}, PickField={'1'}>} concernID or PickID))*100


Previous Month:


=(Count({<MonthField=,Year=,MonthField={'$(=max(month(DateField))-1)'}>} concernID )

/

Count({<MonthField=,Year=,MonthField={'$(=max(month(DateField))-1)'}, PickField={'1'}>} concernID or PickID))*100

View solution in original post

Not applicable
Author

Oops!  Added

balrajahlawat
Champion
Champion

NP, you can try expression shared with you earlier

balrajahlawat
Champion
Champion

Again, how these two tables are linked as their is no mapping of these two tables?