Opening databases global/local when using asynchrone methods
Posted: Mon Aug 29, 2022 10:58 am
When we started Cavo programming many years back, we quickly adopted opening often used database globally. Opening and closing them in a specific screen (class) or even a method was simply costing too much time and added a lot of code.
In X# we could (I understand) add asynchrone code. I can imagine that this could give problems; in a DBF the recordpointer could have been set to specific record to be updated by one procedure while an asynchrone method could change this record pointer in the global database so the wrong record can be updated in the mentioned first procedure.
We use ADS and often new code is done with SQL statements. But that doesn't change the question. I am not sure if it does on using another SQL based database.
How do others deal with that?
Dick
In X# we could (I understand) add asynchrone code. I can imagine that this could give problems; in a DBF the recordpointer could have been set to specific record to be updated by one procedure while an asynchrone method could change this record pointer in the global database so the wrong record can be updated in the mentioned first procedure.
We use ADS and often new code is done with SQL statements. But that doesn't change the question. I am not sure if it does on using another SQL based database.
How do others deal with that?
Dick