custom progress bar
Asked by Alexander Agneessens:

Dear all,

I'm creating a jira structure in which I would like to get a view on the progress based on story points.

The formula that I created is the one below, but I get an error on the last part in bold:

WITH TotalPoints = SUM{ storypoints } :

WITH TotalResolvedPoints = SUM{ IF(Status_Category= "Done"; storypoints) } :

WITH valueProgress=if(TotalPoints \> 0; TotalResolvedPoints / TotalPoints):

WITH customProgress=SUM{**valueProgress}/SUM{1}:**

**CONCAT("{color:green}",**

**REPEAT("?", FLOOR(customProgress/10)), "{color}{color:gray}",**

**REPEAT("?", 10-FLOOR(customProgress/10)), "{color}")**

Alternative was:

WITH customProgress=if(TotalPoints \> 0; TotalResolvedPoints / TotalPoints): CONCAT("{color:green}", REPEAT("?", FLOOR(customProgress/10)), **"{color}{color:gray}",REPEAT("?",10-FLOOR(customProgress/10)),"{color}")**

But also in this one the second part gives an error.

I took a part of the formula from [Wiki Markup Advanced Examples - Structure for Jira - Version 5.2 - ALM Works Knowledge Base](https://wiki.almworks.com/display/structure052/Wiki+Markup+Advanced+Examples#WikiMarkupAdvancedExamples-CustomizableProgressBar) but I don't see what should be changed to the formula in order to make it working..  

Does anyone else see what should change?  

<br />

Thanks!  

Kr,  
Alexander


Answers:
author: Yulia Barbash _ALM Works_
body: Hello [@Alexander Agneessens](/t5/user/viewprofilepage/user-id/3408148)

Yulia Barbash from ALM Works here!

Please try this formula:

WITH customProgress=if(TotalPoints \> 0; TotalResolvedPoints / TotalPoints)\*100:  
CONCAT("{color:green}", REPEAT("?", FLOOR(customProgress/10)), "{color}{color:gray}",  
REPEAT("?",10-FLOOR(customProgress/10)),"{color}")

Where TotalPoints and TotalResolvedPoints are defined according to your fields. In the format options, you will want to select Wiki markup.

Let us know if it helped!

Best regards  
Yulia Barbash  
[www.almworks.com](http://www.almworks.com)

comments: author: Alexander Agneessens
body: [@Yulia Barbash _ALM Works_](/t5/user/viewprofilepage/user-id/4504161) Many many thanks!! Awesome it works! :)  


author: Bill Sheboy
body: Hi [@Alexander Agneessens](/t5/user/viewprofilepage/user-id/3408148)

To be honest, I am not using ALM Works. That being noted...

Your definition of customProgress seems to be recursive, referencing itself. Did you instead want to use another value in the definition?

Kind regards,  
Bill

comments: author: Alexander Agneessens
body: Hi [@Bill Sheboy](/t5/user/viewprofilepage/user-id/1685313),  
Thanks for your reply.  

I wanted to define customProgress as a new value in which I use valueProgress.  

WITH customProgress=if(valueProgress): CONCAT("{color:green}", REPEAT("?", FLOOR(customProgress/10)), **"{color}{color:gray}",REPEAT("?",10-FLOOR(customProgress/10)),"{color}")** Kind regards,  
Alexander  

<br />


author: Bill Sheboy
body: Hi!

Yes, I saw that part. It also appears you are defining customProgress with itself. I bolded the part I wondered about:

WITH **customProgress** =if(valueProgress): CONCAT("{color:green}", REPEAT("?", FLOOR(**customProgress** /10)), "{color}{color:gray}",REPEAT("?",10-FLOOR(**customProgress**/10)),"{color}")

Thanks!


Tags: formula

markup

progress

structure