Recurrent and random fail of NO update on Calculations fields
Hi! I have a recurrent and aleatory problem with some podio calculations fields.. especially with the simplest calculations. I'm gonna try to explain the problem with an example;
I have 3 apps with this fields;
1 Bills App to record the sales for the Customers
Relation field: Customers
Number field: Bill Amount
2 Receipts App to record the payments from the Customers
Relation field: Customers
Number field: Receip Amount
3 Customers App to record Customers and to calculate the diference between Bills and Receip amounts
Calculation field 1: Total of Bills amounts (works great)
Calculation field 2: Total of Receip amounts (works great)
Calcultaion field 3: Diference between Calc. field 1 and Calc. field 2. Formula: "@Total of Bills amounts + @Total of Receip amounts"
The last calculation field (3) sometimes fail! Then, I edit the template, just give an "enter" at the end of the formula of calc. field 3 and It's begin to work Ok till the next aleatory fault that could be in a week.. or after tens of related items.
A numeric example would be;
Calc. field 1 = 10, Calc. field 2 = 20, Calc. field 3 = 20! Then I have to options to solve de problem...
a) Make a change on related fields of calculation, so the calculation is updated and normally the problem disapear
b) Edit the App template, and give an "enter" at the end of the formula, so the calculation is updated and usually the problem disapear
Conclusion; I guess the problem is that for some REASON the calculation field does not takes the last change on related fields or something like that. So I need to know that REASON and a SOLUTION so ALWAYS the calculation field get updated to the last change on related fields.
To put you on context I see this problem on a organization which manage thousands of dollars a day.. is very importan for them to get calculations OK.
Finally I'll atach some pictures of the steps of the fault in a specific case
Picture 1:
Field "Artículos Pedidos" is a related item with posibility of multiple relations
Field "Cantidad Artículos" is a calculation field which count the quantity of related items from the field "Artículos Pedidos", the formula is;
"var art = @All of Artículo Pedido;
for (var i=0; i<art.length; i++) { } i"
In this picture the result of "Cantidad Artículos" is 0 (cero), a wrong result
Picture 2: I show the template edition page and the formula
Picture 3: Same of Picture 2 after give an "enter" at the end of the formula, the calculation get update to 1 (one)...
Picture 4: The result change on the item
Please help me! I get this error on diferent Apps

Hi Rodrigo,
my tip: Submit a support ticket https://help.podio.com/hc/requests/new
Btw: You don't need a forloop for counting the quantity of related items:
@All of Artículo Pedido.length
does the same.
If it doesn't return the right result, check if you have select the right variable token. Do you have a vice versa relationship between the 2 apps? If so, you have an outgoing and an incoming relation and an own token for each.Rainer

Hi Rainer! Thanks for your time reading this long post, I really appreciate this.
Maybe my post was too long and the problem get lost, but It's not a common problem with calculations which I'm trying to explain.
I know the ".lenght" to count elements of a vector matrix, previously that was the formula but I used to have these problem more frecuently, so I use a "more complicated" way to get the same value and the calculations fails less to update, don't ask me why.... These two apps does not have vice versa relationship.
For further clarifications I also know the status.podio.com web, when there is a delay on calculations they get ok automatically after the delay, but It's not this case because the calculation doesn't get rigth till I make a change MANUALLY. Also I know a calculation fields only get updated if any of the related variables changes. But the randomly fault I see is exactly related with that, to summarize the problem is;
"When a related variable of a calculation field changes.. the result of calculation does NOT change!" (this only happen some times, randomly)
In the pictures of the post I´ts clear that the first result is Wrong and then I make a change manually (without changing the formula) and the result gets right.
I've a lot of calculations on my organizations (for years), a lot of them are a kind of small ERP wich manage stocks and money.Those formulas used to work ok for a long time till I began to see these stranges and random problem with calculation update.
I already make a ticket on podio support. Thanks again Rainer!

Hello Rodrigo,
sorry for explaining basics :) I'm an Authorized Podio Partner who does many many calculation for many clients. I've never seen that behaviour of .length for manually added relations  only for bulk imported relations (Excel import).Podio tweaked it some month ago, but it still happens randomly. And cause it's randomly it's hard to find the reason. I'm curious if the support can help you, would be great if could give a feedback if this could be solved for you. Thanks in advance!
Rainer

Hi Rodrigo,
I first noticed this a year ago and received this response from support
https://help.podio.com/hc/enus/requests/124849
George Lock
June 07, 2016 14:27
Typically, when a calculation field messes up like that, we recommend removing the field and adding it back to refresh it. Since changing the calculation can have the same effect, at this point, there is not much more I can do at this time. If you enter a new time sheet and it happens again, then I will need you to invite me into the workspace to do some more troubleshooting. For now, let's wait to see if the issue occurs again and we can move forward from there.
Best,
George
I only notice the errors when I export and analyze data from Podio and attempt to reconcile, otherwise the error can be hard to find. It's not a failure of the formula itself but a failure for the formula to update on just one item. The fix is simple enough but finding which item is not working, or even seeing that it's not working, is not so easy.
IMHO this is a critical bug in Podio that I am really disappointed they haven't addressed. 
Some general help to explain how calculations work and what might cause the error if calculations fail to update: https://help.podio.com/hc/enus/community/posts/360015495711Calculationsbehaviour
// Podio Team

Rob Sronce, I 100% agree! The development team to Podio refuses to fix major bugs such as this, which makes podio a scary option for me to build my business around. I will keep using it until I find a better alternative, but hopefully that is sooner rather than later.
Please sign in to leave a comment.
Comments
7 comments