Servoy 5.1 beta 3

jcompagner:
that first one doesnt use the selected index.
Because that just generate 1 sql statement that updates the whole foundset at once.
Are you sure that you use it like that? What does the performance tab tell you when you clear it, then run it?
What kind of sql statements are fired?

Hi Johan,

My code :
var _fs = _fs0.duplicateFoundSet() // _fs0 is initial foundset
// _fs.setSelectedIndex(1)
var _fsu = databaseManager.getFoundSetUpdater(_fs)
_fsu.setColumn(_field, _value)
var _ok =_fsu.performUpdate()
if (_ok) {
databaseManager.saveData()
}

In performance tab appl.server :
00:00:016 4 00:00:002 Update update glb_supplier set log_modification_dt=?, glb_currency_id=? where glb_supplier_id = ? and owner_id in (?, ?)

So Servoy goes into foundset iterating mode in stead of 1 update statement for the whole foundset. In my test I have 6 records in the foundset and the selectedIndex is 2 (6-2=4 updatestatements)

I think the complete foundset updater does not work as described…