Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Set analysis not bringing through data

Hi

I have an issue with set analysis

I have cloned charts one uses this expression and it is working fine

count(distinct(if(MeterType = 'K' and ExpectedConsumption = 0 ,UnitNo)))

The other chart I have the following set analysis, the syntax seems to be OK but it is just giving me no data to display

Count(distinct{$<MeterType = {"K"} , ExpectedConsumption = {0} > } UnitNo)

What am I doing wrong. the value in ExpectedConsumption  comes from SQL where it is a numeric(5,3)

1 Solution

Accepted Solutions
simospa
Partner - Specialist
Partner - Specialist

Hi,

changing to

count({ $<[MeterType]={'K'}, [ExpectedConsumption]={0.000}>}  DISTINCT UnitNo)

it works, so the problem is in the ExpectedConsumption format

Hi

S.

View solution in original post

9 Replies
alexandros17
Partner - Champion III
Partner - Champion III

try with

Count({$ <MeterType = {'K'} , ExpectedConsumption = {'0'} > } Distinct UnitNo)

Gysbert_Wassenaar

Looks ok to me at first glance. Can you post a qlikview document that demonstrates the problem?


talk is cheap, supply exceeds demand
Not applicable
Author

Not working sorry

Not applicable
Author

how do I shrink it enough to only show certain records?

giakoum
Partner - Master II
Partner - Master II

Make some selections first and then

File --> reduce data

Not applicable
Author

Check the data cleansing tab, you will see one with no data and the other with data

simospa
Partner - Specialist
Partner - Specialist

Hi,

changing to

count({ $<[MeterType]={'K'}, [ExpectedConsumption]={0.000}>}  DISTINCT UnitNo)

it works, so the problem is in the ExpectedConsumption format

Hi

S.

Not applicable
Author

Thanks a million, can you explain why mine was not working and yours, so so I understand exactly what the issue is

simospa
Partner - Specialist
Partner - Specialist

I think that the format in which ExpectedConsumption field iid not recognize as a number by set analysis, but not sure.

If you try to create a chart with sum(ExpectedConumption) as expression you get 0.000, if sum(ExpectedConumption)*1 you get 0.


S.