After updating to latest 4.1.1 (from 3.x), we have a huge regression in BulkCopy when using the proprietary Oracle strategy using array-bound parameters.
All queries on the same DataConnection after BulkCopy fail with an InvalidCastException, that can't convert a random type (int32, string, DateTime) to Array.
It seems linq2db tries to re-use DbCommand objects, but it doesn't reset them properly.
Specifically, after the bulk copy, the ArrayBindCount property is not set back to 0.
So future queries that re-use the command are still in array binding mode... and fail because their parameters are not set to array values, of course.
After updating to latest 4.1.1 (from 3.x), we have a huge regression in BulkCopy when using the proprietary Oracle strategy using array-bound parameters.
All queries on the same
DataConnectionafterBulkCopyfail with anInvalidCastException, that can't convert a random type (int32, string, DateTime) to Array.It seems linq2db tries to re-use
DbCommandobjects, but it doesn't reset them properly.Specifically, after the bulk copy, the
ArrayBindCountproperty is not set back to 0.So future queries that re-use the command are still in array binding mode... and fail because their parameters are not set to array values, of course.