Hello,
When the code (below) is executed the active record is locked and a dialog to choose a projectnumber is shown. When a choice is made, it is returned as result, if the result is not null, the projectid in the active record is updated. Everything works as expected.
My question. Is acquireLock a feature that is only working between servoy clients, or is it supposed to use the pessimistic locking features of the MSSQL or Oracle Server?
What if I want to use optimistic locking within Servoy? (We have also Web based clients using the same database)
try
{
databaseManager.acquireLock( foundset, 0 )
try
{
var result = forms.selectProject.showDialog( this )
if( result != null )
{
projectid = result;
}
}
catch( error )
{
throw error;
}
finally
{
databaseManager.releaseAllLocks();
}
}
catch( error )
{
plugins.dialogs.showErrorDialog( "Error", error, "Ok" );
}