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

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Gabbar
Specialist
Specialist

Same Set Expression giving different result with and without field

Gabbar_0-1672835187235.png

Image 1

 

Gabbar_1-1672835217513.png


Image 2

In image 1 and 2 C1 is same measure, but without field it is giving C1 and adding any field is giving a table like Image 2(total of measure is same in all the cases).
Help Please

 

Labels (5)
14 Replies
ogster1974
Partner - Master II
Partner - Master II

Try using the Aggr function example Sum(Aggr(C1,[REGION NAME])) to return the same result.

Gabbar
Specialist
Specialist
Author

Thanks Sir
I also want to know why this is happening.

 

vinieme12
Champion III
Champion III

Can you post the expression ??

and a snapshot of the data model ??

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
ogster1974
Partner - Master II
Partner - Master II

Need to see what's behind C1 to help answer that.

 

Gabbar
Specialist
Specialist
Author

There is only a single table in data model having all the require fields.

Set expression is:

Count({<[Expiry Date]={">=$(=44652)<=$(=44742)"},Eid=e({<[Created Date]={"<=$(=44742)"},[Expiry Date]={">=$(=44742)"}>})>
*<[Expiry Date]={">=$(=44652)<=$(=44742)"},Eid=e({<[Created Date]={">=$(=44742)<=$(=44834)"},[Expiry Date]={">=$(=44834)"} >})>}distinct Eid)

Gabbar
Specialist
Specialist
Author

There is only a single table in data model having all the fields.

Set expression is:

Count({<[Expiry Date]={">=$(=44652)<=$(=44742)"},Eid=e({<[Created Date]={"<=$(=44742)"},[Expiry Date]={">=$(=44742)"}>})>
*<[Expiry Date]={">=$(=44652)<=$(=44742)"},Eid=e({<[Created Date]={">=$(=44742)<=$(=44834)"},[Expiry Date]={">=$(=44834)"} >})>}distinct Eid)

vinieme12
Champion III
Champion III

can you explain what exactly do you want to calculate ! a lot of overlapping criteria's here

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
Gabbar
Specialist
Specialist
Author

I want to calculate count of eid which expired between dates 44652 and 44742, and are not renewed again before 44834.
Example if an eid expired between those dates and is renewed again on or before 44834 i dont want to count it,  but if it expired and is renewed after 44834 i want to count it, also if it is not renewed than i also want to count it.

vinieme12
Champion III
Champion III

try below

=Count({<Eid=

p({<[Expiry Date]={">=$(=44652)<=$(=44742)"}>-<[Created Date]={">=$(=44742)<=$(=44834)"} >} Eid)

>}distinct Eid)

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.