8 Replies Latest reply: May 23, 2014 1:48 PM by ralph snijckers

# Counting same data blocks

Hello,

The database has a range with products, date and a code number.

Í want to count for each product:

How many days the code "500" occur in a block of associated days.

How many associated blocks with code number "500" the are.

See attached file.

Thanks

• ###### Re: Counting same data blocks

Hi Ralph

Create a graph with

Product Code as Dimension

Count(Date) as expression

if you need just one code, select it

best regards

Chris

• ###### Re: Counting same data blocks

Here it is my example

• ###### Re: Counting same data blocks

Dear ,

Kindly find the attached file.

Thanks,

Mukram.

• ###### Re: Counting same data blocks

Hello Mohammed,

Thanks voor the reply.

This is not what I mean.

See attached file tab 2

• ###### Re: Counting same data blocks

... have you seen my example?

let me know

• ###### Re: Counting same data blocks

Yes,

Thank you, but it's the same as Mohammed and not what I mean.

My question is not very good due my bad english.

I attached a new JPG (knipsel) into my question.

Did you see the second tab of my Excel document?

Here you can see what i want.

• ###### Re: Counting same data blocks

When you load the data in concat the 2 fields and count the concatenated field?

• ###### Re: Counting same data blocks

Hello Felim,

That doesn't work.

In Excel it's the formular: IF(Code = 500; Above CELL + 1; 0)

In Qlikview: IF(Code = '500', ???? + 1, 0)

Dimensions is Product.

Code range 1

500     1

500     2    it's 500 -> 1 + 1 = 2

100     0    it's not 500 -> 0

110     0

500     1

500     2

500     3

etc..

With this table I can take the MAX number en thats what I want.

MAX(Range 1) = 3

I hope this will help and that you can and will help me.