Background:
I have written a small Extension for the ObjectContext to handle verry performant inserts for large EntityObject enumerations.
public static int InsertByCommand(this ObjectContext objectContext, bool returnIdentityOrGeneratedValues, IEnumerable entitiesToInsert) where T : EntityObject
{
...
}
this extension creates as many as needed OracleCommands and executes them via dynamically created INSERT-Statement for all EdmProperties of T and calls ExecuteArray for the (ObjectContext.Connection as EntityConnection).StoreConnection.
Each identity or computed Property is mapped to an output-Parameter all other Properties are mapped to inputParameters.
This works really cool and is many times faster than ObjectContext.SaveChanges();
Question 1:
how do I declare a Devart.Data.Oracle.OracleParameter for output for
DbType.Int64???
var test = new Devart.Data.Oracle.OracleParameter();
test.DbType = DbType.Int64;
does internally set
test.DbType ==> to decimal!!
I have trouble with ExecuteArray() all OracleParameter array values with
ParameterDirection.Output getting an invalid cast exception because the
int64[] array value ist not compatible with decimal[] array value.
For input-direction it works fine... if I have set an int64[] as parameter value filled with all int64 keys.
But for output I have to write painful if else code to handle the difference for input and output direction and have to keep attention also during writing back the result array to real objects with int64 properties.
Question 2: Why do you not use RETURNING INTO clause for inserts???
During my research i have seen, Devart ?? or Microsoft EntityFramework??
uses cursor and select last inserted value for getting back StoreGeneratedIdentity and StoreGeneratedComputed values....
for each insert for each entity???
(I use RETURNING INTO clause for my mass insert and it works great!!)
Question 3:


Could Devart provide such a helpful extension supporting "all" internal hidden and dotfuscated features....
(I solved only the data types we use up to now....)
(Associations are also not supported up to now...)
Any advice or help available??
Thanks,
Roman