Page 1 of 1

EF With BatchUpdates

Posted: Tue 17 Apr 2012 21:43
by leolosi
Good evening,

I have a question about the dotConnect for MySQL with Entity Framework.
I looked at the documentation on how to use the method BatchUpdates but not get any relevant example.

I created an EF and insert the following lines of code.

MySqlEntityProviderConfig MySqlEntityProviderConfig.Instance = config;
config.SqlFormatting.Disable ();
config.DmlOptions.BatchUpdates.Enabled = true;
config.DmlOptions.BatchUpdates.AsynchronousBatch = true;
config.DmlOptions.BatchUpdates.BatchSize = 30;
config.DmlOptions.InsertNullBehaviour = InsertNullBehaviour.Omit;
config.DmlOptions.ReuseParameters = true;

However, the EF does not insert records into blocks of 30 lines.
Does anyone have a complete example of EF inserting records into blocks.

thank you

Posted: Thu 19 Apr 2012 14:49
by Shalex
I have just checked the BatchUpdates feature using your settings with dotConnect for MySQL v 6.80.341. It works. Refer to http://www.devart.com/blogs/dotconnect/ ... iders.html. Turn on the dbMonitor tool to check the SQL commands which are sent to the server (whether BatchUpdates works or not).
Download link: http://www.devart.com/dbmonitor/dbmon3.exe
Documentation: http://www.devart.com/dotconnect/mysql/ ... nitor.html

Does it help? Which version (x.xx.xxx) of dotConnect for MySQL are you using?

Posted: Tue 24 Apr 2012 10:47
by leolosi
Shalex wrote:I have just checked the BatchUpdates feature using your settings with dotConnect for MySQL v 6.80.341. It works. Refer to http://www.devart.com/blogs/dotconnect/ ... iders.html. Turn on the dbMonitor tool to check the SQL commands which are sent to the server (whether BatchUpdates works or not).
Download link: http://www.devart.com/dbmonitor/dbmon3.exe
Documentation: http://www.devart.com/dotconnect/mysql/ ... nitor.html

Does it help? Which version (x.xx.xxx) of dotConnect for MySQL are you using?

Hello Shalex,

I am using Devart version 5.0.382.0.

I am using the Entity Framework (EDMX) native. NET platform and want to integrate it with the option BatchUpdates Provider Devart.

Is this possible?

Tested by DBMonitor but does not work, BatchUpdates works only with EF (EDML)?

thank you

Posted: Thu 26 Apr 2012 11:14
by Shalex
Batch Updates works with both EDMX and EDML models. Please make sure that Batch Updates limitations are not applied to your case: http://www.devart.com/blogs/dotconnect/ ... imitations.