Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

Bar Chart with Custom Ranges

Hello All,

I am struggling with creating the necessary calculated dimension / expression to create a bar chart with custom ranges.  Please see my data set below

Trade IDAmount in EUR
56465461€ 23,000.00
564894€ 51,500.00
5616516€ 100,000.00
4894198494€ 123,000.00
8165161€ 890.00
984194€ 12,312,323.00
5615618€ 590.00

I am trying to create the bar chart showing the # of trades that fall into the following buckets while using an "if Statement":

Amount in EUR - Buckets
0 - 25,000
25,000 - 50,000
50,000 - 100,000
100,000-200,000
200,000 +

Each Trade ID is unique.  Please help or my keyboard gets thrown across the room!

3 Replies

Re: Bar Chart with Custom Ranges

Hi

Try like this,

In script ,

Load *, if(Amount in EUR >= 0 and Amount in EUR <= 25000,'0-25000', if(Amount in EUR <= 50000,'25000-50000',

if(Amount in EUR <=100000,'50000-100000',if(Amount in EUR <= 200000, '100000-200000','200000+')))) as Bucket from tablename;

Then use Bucket as dimension, and count(Trade ID) as Exp

Hope that helps

Not applicable

Re: Bar Chart with Custom Ranges

I agree that should work, but I am also trying to understand how to do this through using "if statements".  I believe I will need to create a custom dimension, but I am having trouble with getting getting started in the right direction...

any ideas?

Re: Bar Chart with Custom Ranges

Hi

Please see the attached file..

Sheet name: Bucket

Hope it helps

Community Browser