I'm not an expert in MySql. But as I read from the document, you can use pure SQL to lock the table. When the table is locked, you get errors if another thread tries to write to it.
Here is the suggestion. The rowset associated with any dataprovider has a command property. This command propoerty takes any valid SQL statement.
You could try the following.
- Get the original command and put it in a temporary variable
- Set new command (SQL) that locks the table and execute the rowset
- Execute the dataprovider commit (sets Update SQL to cached rowset)
- Set new command that unlocks the table to rowset and execute
- Set back the saved command back to the rowset
I haven't tried this, but worth trying
- Winston
http://blogs.sun.com/winston