# Creating chart with aggregated data values

• 0
• Question
• Updated 1 year ago
I'm creating a pie chart from a column where the number of days to resolve an issue could range from 1 to any number. In my chart, I'd like to aggregate the day values to: 1, 2, 3-5, 6-10 and More than 10. My number of days field property is numeric. I've tried creating a calculated column but am having trouble with the formula. I tried an "If" formula with a series but that didn't work. Any suggestions?
• 214 Points

Posted 1 year ago

• 0
• 602 Points
did you try a case statement?

QuickBaseCoach App Dev./Training, Champion

• 67,278 Points
np,

Make a new formula text field called Issue Resolution Groups with the formula

IF(
[Issues resolution days] < =1, "  1"
[Issues resolution days] < =2, "  2"
[Issues resolution days] < =5, " 3-5"
[Issues resolution days] < =10, " 6-10"
[Issues resolution days] < =11, "11+")

Then base your chart in that field for the "series".

I have contrived the values with leading spaces to get them to sort properly.
(Edited)

QuickBaseCoach App Dev./Training, Champion

• 67,278 Points
Correction
IF(
[Issues resolution days] < =1, "  1"
[Issues resolution days] < =2, "  2"
[Issues resolution days] < =5, " 3-5"
[Issues resolution days] < =10, " 6-10", "11+")
• 214 Points

Hi there - Trying it now. I see the different clusters are on separate lines. Does that mean each one is it's own formula? If not, how do I separate [Issues resolution days] < =1, "  1" from [Issues resolution days] < =2, "  2" for example--comma? Thanks!

• 214 Points

I'm pretty literal with the help at this stage in my QB - sorry, super green!

QuickBaseCoach App Dev./Training, Champion

• 67,278 Points
Sorry, I forgot the commas. It is all one formula.

IF(
[Issues resolution days] < =1, "  1",
[Issues resolution days] < =2, "  2",
[Issues resolution days] < =5, " 3-5",
[Issues resolution days] < =10, " 6-10", "11+")
• 214 Points
Worked like a charm! You are the bomb. Thanks so much for your help today.