Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

Could not convert the field value to a number.

I am trying to make multiple fields automatically sum up into another custom field for my WSJF scores.  It seems as though I have everything set correctly but I cannot get the value to show up on the card. Here are a few screenshots to walk you through what I have set up.


If Time Criticality, User Business Value, or Risk Reduction-Opportunity Enablement Value change:Screen Shot 2021-01-12 at 3.58.09 PM.pngThen create new variable that sums up the 3 fields, here is the entire syntax:

= {{#=}}{{Issue.Time Criticality|0}} + {{Issue.User Business Value|0}} + {{Issue.Risk Reduction-Opportunity Enablement Value|0}}{{/}}Screen Shot 2021-01-12 at 3.58.20 PM.png

Then set Cost of Delay field equal to the variable CostofDelayScreen Shot 2021-01-12 at 3.58.32 PM.png

It even looks like the rule is working as in the error message it is showing me that it is totaling correctly but it is throwing this error and not filling in the Cost of Delay field on my cards.Screen Shot 2021-01-12 at 3.57.56 PM.pngIf anyone could help me out with this it would be much appreciated. 



3 answers

1 accepted

0 votes
Answer accepted
Yvan Martin Atlassian Team Jan 19, 2021

Hi there Brett,

Developer from Automation here.

Looking at your example it looks as though you've put an "= " at the start of the smart value, which will output something like = 30 which is considered text. If you remove that and just had {{#=}}{{Issue.Time Criticality|0}} + {{Issue.User Business Value|0}} + {{Issue.Risk Reduction-Opportunity Enablement Value|0}}{{/}}

Then your rule should work correctly, as a note since you aren't really using that variable for anything other than editing Cost of Delay, then you can actually just put that smart value formula into the edit field directly.

If you are still having issues with your rule, then you can get in touch with support here:

When field Value changes

- calculate and set value to cf "Cost of Delay" in one step

What is the purpose of using the variable {{CostofDelay}} when you can assign that value right in Edit Issue?

It is possible along the way the smart value process is converting to a String, so you "see" a number but it is not one in the end. 

0 votes

Check the types of the fields you are working with - the error message suggests you are trying to perform mathematical operations on fields that are not numbers.

All fields are set to number fields

I'm sorry, I was unclear.  The field might contain what you think is a number, but is the field type a number?   The error message could be telling you the value is a string or even option.

Like John M Funk likes this

Yes, I knew what you meant.  The field types are all number fields for all 4 fields in this equation, which has me at this dead end.  What i really dont understand is that in the final screenshot it shows a "cost of delay" of 30 which is correct and if I change the numbers around the rule runs again and recalculates the Cost of delay correctly.  The only issue is that the error keeps popping up and the actual cost of delay field on the card is not populating.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Apps & Integrations

Marketplace Partner Spotlight: AppLiger

This month the spotlight is on AppLiger. We caught up with Pavel Pavlovsky, CEO and Product Manager, to learn how the company started and what fuels the team's creativity.    Atlassian:...

389 views 0 7
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you