1. Is there a way to perform bulk insert/update without switching StoreGenerationPattern from Identity to None?
We are investigating the possibility to implement this feature, but can't tell any timeframe at the moment. We will inform you when any results are available.
As I understand Array Binding would help there?
Yes, you could use Array binding ->
http://www.devart.com/dotconnect/oracle ... yBind.html.
You could also try using the OracleLoader class ->
http://www.devart.com/dotconnect/oracle ... oader.html.
JIC: we recommend you to use the OracleLoader class due to the fact, that it was improved since dotConnect for Oracle 7.9.322. For more information please refer to
http://forums.devart.com/viewtopic.php?f=1&t=27982.
can we retrieve metadata about table/column names corresponding to entities and about constraints defined in the model to build SQL
It is possible to do by creating a custom template, which will generate the code according to the existing model (if you are working with Entity Developer, create template for it via the Model Explorer-> Templates-> New Blank Template; if it is EDM Wizard/Designer, create a standard T4-template).
If your model objects contain all columns of the corresponding database table and there are no inheritances/complex types, the generated code could be like this:
Code: Select all
public static void LoadDepts(OracleConnection connection, IEnumerable<Dept> allDepts) {
// check connection and allDepts
// ...
// Load data
OracleLoader loader = new OracleLoader("YOUR_TABLE_NAME", connection);
loader.CreateColumns();
loader.Open();
foreach (var dept in allDepts) {
loader.SetValue("DEPTNO", dept.Deptno);
loader.SetValue("DNAME", dept.Dname);
loader.SetValue("LOC", dept.Loc);
loader.NextRow();
}
loader.Close();
}
JIC: If you don't have a lot of classes and your model and tables don't change, then this code could be written manually.