stored calculation fields weirdness

Hi all,

Again, need your help. Someone here must have experienced the same thing.

I have a huge database with a stored calulation field (it’s the audit trail table- it is a calculation field that stripes out the “.” and “;” in the pk_data field)

I now need to write scripts to search within the store calculation field “pk_data_numonly”. However, when I do a search, no record is found. The calculated field shows NULL on SQL server backend. Then I do a wildcard search on the original record and actually show the record in servoy view. Then i go back and repeat the same search in “pk_data_numonly” field, now, the records ARE found.

I’ve noticed this on exports as well. Seems like the behavior of calculated field is that it is not updated until AFTER it is shown in a servoy view(layout)

Anyone have a work around around this? or experience this behavior

if you add a calculation then yes servoy first needs to have touched this.

Or are you saying that when you create a new record that has that calculation then when you save it (the calc itself is not shown anywhere) the calc column is also not updated to the right value?

If you just made a calc on a large table where the records never have been into servoy and saved once. Then yes the calc will not be updated
For this we have

databasemanager.recalculate(foundset_or_singlerecord)

johan