# New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for
Did you mean:
Highlighted
Contributor II

## Grouping By Dollar Value

I am looking to organize my data by groups by revenue. The revenue is the only calculated field. The groups I am working with are as follows:

0-100

100-300

300-500

500+

Any idea as how to tackle this? I'm still very new to Qlik code and syntax.

Thanks

1 Solution

Accepted Solutions
Highlighted
MVP

Assuming Revenue by XYZ field, you can try this to create your buckets on the front end

Aggr(

If(Sum(Revenue) < 100, Dual('0-100', 1),

If(Sum(Revenue) < 300, Dual('100-300', 2),

If(Sum(Revenue) < 500, Dual('300-500', 3), Dual('500+', 4)))), XYZ)

Also, look here:

Buckets

8 Replies
Highlighted
MVP

Grouping how? Revenue per Customer? Revenue per Year? or just individual rows of revenue?

Highlighted
MVP

Assuming Revenue by XYZ field, you can try this to create your buckets on the front end

Aggr(

If(Sum(Revenue) < 100, Dual('0-100', 1),

If(Sum(Revenue) < 300, Dual('100-300', 2),

If(Sum(Revenue) < 500, Dual('300-500', 3), Dual('500+', 4)))), XYZ)

Also, look here:

Buckets

Highlighted
Contributor II

Thanks for the response. That worked perfectly. If I wanted to make these same categories on the back end to apply to multiple tables or sheets how would I go about that?

Highlighted
MVP

Again it would depend on which level are you wanting to do it at? Row Level? One dimension level? Multiple dimensions level?

Highlighted
Contributor II

What do you mean by multiple dimensions level? Is that multiple categories?

Highlighted
MVP

Would you be able to share a sample with expected output?

Highlighted
Contributor II

Something like this. Two tables:

 Rev Cat pre policy change post policy change 0-100 order qty order qty 100-300 order qty order qty 300-500 order qty order qty 500+ order qty order qty Rev Cat pre policy change post policy change 0-100 Total \$ orders + Fees Total \$ orders + Fees 100-300 Total \$ orders + Fees Total \$ orders + Fees 300-500 Total \$ orders + Fees Total \$ orders + Fees 500+ Total \$ orders + Fees Total \$ orders
Highlighted
MVP

I was looking for a numerical data with specific output you look from that raw data