DB insert operations are slower when using parallel.foreach than regular foreach
I have a function that loops through my list of objects, makes some checks on them and saving to an SQL server DB.

The number of objects I should save can be tens of thousands, so I decided to use parallel framework to make it faster. I use parallel.foreach to do that.

It works, but I recognized it is slower than 'normal' foreach. E.g. in my last test a list of my objects are processed in 2:41.35 minutes, regular foreach do the does it in 2:14.92. The difference is nearly half a minute.

Is it a common behavior for DB insert operations in parallel framework? Is it advised to use parallel.foreach to make DB insert operations?

Thx!

VS2010/.Net4/c#
DB insert operations are slower when using parallel.foreach than regular foreach
===

I have a function that loops through my list of objects, makes some checks on them and saving to an SQL server DB.

The number of objects I should save can be tens of thousands, so I decided to use parallel framework to make it faster. I use parallel.foreach to do that.

It works, but I recognized it is slower than 'normal' foreach. E.g. in my last test a list of my objects are processed in 2:41.35 minutes, regular foreach do the does it in 2:14.92. The difference is nearly half a minute.

Is it a common behavior for DB insert operations in parallel framework? Is it advised to use parallel.foreach to make DB insert operations?

Thx!

VS2010/.Net4/c#