Thanks, Chris.
The only difference I can see is the WHERE clause in the UPDATE statement.
With the option checked, the WHERE clause is very long, and with the option
unchecked, there's only one field included in the WHERE clause.
I create my UPDATE statement using the following,
MyDataAdapter.UpdateCommand = cmdBuilder.GetUpdateCommand()
and it has a long WHERE clause. I wish I can have a short WHERE clause that
only checks the PK field and that's just like the one the wizard createed
with the open turned off.
The long WHERE clause catches "Concurrency violation" exception which I
realy don't care at this moment.
Thanks.
"Chris" wrote:
John wrote: In 'Data Adapter Configuration Wizard' for OleDbDataAdapter, there's a
checkbox called 'Use optimistic concurrency' that allows to turn on/off the
option. I don't use the wizard, I create MyDataAdapter using the following,
MyDataAdapter = new New OleDbDataAdapter(MySql, MyDatabase)
The question is how to turn off the 'Use optimistic concurrency' option in
my case. Thanks.
Not too sure myself, but if you look at the code the wizard creates when
you use the wizard it will show you how it does it. The code will be in
the "windows generated area" Remember, the wizard just dumps in code,
there is no hidden magic under it.
Chris