Do you have this set to be an unstored calculation? If not, you need to do that:
Select the field in Manage databases, click on Options (going to the dialog where you set the calculation)
Click Storage options
Check the box Do not store calculation results...
I do have the field as NON-STORED so that's not it...
Could it be something in the relationship? If so, how can I verify?
My field is already a Number type and when I try to uncheck Do not store calculation results -- recalculate when needed... then I get this window:
"The calculation "DollarsSum" cannot be stored or indexed because it references a related field, a summary field, an unstored calculation field, or a field with global storage."
DollarsSum is defined as:
Sum( T06a_con_StatementLines||id_concepto|::LINE_DOLLARS )
Why the message? What am i doing wrong?
What you are doing wrong is exactly what the message says you are doing wrong.
If the calculation references related data, it can ONLY be set as unstored.
But Suresh above says that my calculated field should be indexed - meaning that's why it is not working..
Sometimes the calculated field shows "?" while some times it shows a value...
Yes, however Suresh above is saying that I should index that field (which requires storing it) and he states that is the reason the calculated field only works sometimes...
BTW, what could be causing the calculated field display "?" sometimes and other times a correct sum?
Appreciate your help!!
It cannot be indexed and that has nothing to do with it.
Sometimes a "?" in a field just means the field size is not large enough for the value it holds. What happens when you click into this field? Do you see a valid result?
If you have a skinny field but it is holding 123.420342423424312949 then it will show as "?"
Well I have found 2 different reasons why the calculated field shows a "?"!!
One is what you just stated: a very small field for it's contents! (Great, thanks!!)
and the other occurs when there are NO corresponding statement lines that match the id_concept, and therefore the navigation that has to occur to make the SUM possible does not occur!!
Do you agree with the second reason too?
Regarding the second part of your reply. No; I do not agree. But this may be partly a language or terminology issue.
Navigation is not involved here. I do not know what your intent is when you use that word in this context.
In the FileMaker context, navigation means moving from record to record or field to field, and would also involve a description of how you navigate. (Native filemaker controls, keyboard, etc)
I think you are right on case 2
i found some corrupted or at least not properly entered records that seem to be causing the other "?"
i Will input fresh data and retest and let you know
but my gut tells me you are right
thanks a lot!!
Note that one of your choices when you display numbers on a layout, beside sizing the field, is to control how many decimal points display. Given the number above, (123.420342423424312949) you might regard that as valid.
But you can design the field to show only two decimal points.
So when you look at the field, you see 123.42
When you print the layout; you see 123.42
When you click into the field, you see 123.420342423424312949
You can also control the calculation itself; so that it rounds the value.
Or you can control the precision of the source fields ( the fields in the item records).