Mini truck stop.
Finally, something exciting to discuss – money!
The problem, by Jerry
I have two rollup fields on a form – one for decimal and the other for currency – both pulling from the same child entity.
The currency rollup won’t display a value.
If I make a change to a field and save or just view the record and then go back to the grid view, no error message. However, if I refresh either calculated field I get this error when I navigate from the form:
<Message>’timeToString’ is undefined</Message>
It is on 126.96.36.199
Self-healing Solution, by Jerry
We finally figured out the issue. The distractor for us was that the error message <Message>’timeToString’ is undefined</Message> didn’t help us.
Side note – blah-blah, winge-winge (sensored – by t.j.)
How did this happen?
- Import data into child records with currency data fields.
- Create Currency Rollup field on Parent Record
- Error gets thrown because child records don’t know what currency they are and the rollup process doesn’t like that. Child records are still happy.
Fix – set transactioncurrencyid for the imported records.
Is this a bug or is it behaving as expected?
Affirmation, by Mitch
That is to be expected.
Any time you have a currency field you must also have a currency added to the record. Without that, it does not know how to display the currency.
Normally, through the UI, this field is automatically populated but if creating records programmatically, you must always ensure that the transactioncurrencyid is populated. Import would be just another programmatic access method.
Good blog post there… (so here it is – t.j.)