Oracle EF 4.1 Code First with no AutoNumber Column

Discussion of open issues, suggestions and bugs regarding Entity Framework support in ADO.NET Data providers
Post Reply
jared
Posts: 10
Joined: Wed 12 Oct 2011 22:12

Oracle EF 4.1 Code First with no AutoNumber Column

Post by jared » Fri 14 Oct 2011 19:00

There seems to be a bug that if your Code First model does not contain any AutoNumber (DatabaseGeneratedOption.Identity) Columns, then it will not initialize the schema (create the tables).

It sends the following command:

Code: Select all

SELECT COUNT(*)
  FROM SYS.ALL_SEQUENCES
 WHERE 
and it errors out because it has an incomplete WHERE statement, and then creates no tables...

If I create a dummy table with an AutoNumber column, then it works:

Code: Select all

SELECT COUNT(*)
  FROM SYS.ALL_SEQUENCES
 WHERE (SEQUENCE_OWNER = SYS_CONTEXT('USERENV', 'CURRENT_SCHEMA') AND SEQUENCE_NAME = 'Dmy_SEQ')

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Mon 24 Oct 2011 12:19

We have reproduced the problem with incomplete SQL. We will investigate the issue and notify you about the results.

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Thu 27 Oct 2011 10:31

The bug with Database.Exists() when there is no entities with DatabaseGeneratedOption.Identity in model is fixed. We will post here when the corresponding build of dotConnect for Oracle is available for download.

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Fri 11 Nov 2011 16:23

New build of dotConnect for Oracle 6.50.244 is available for download now!
It can be downloaded from http://www.devart.com/dotconnect/oracle/download.html (trial version) or from Registered Users' Area (for users with valid subscription only).
For more information, please refer to http://www.devart.com/forums/viewtopic.php?t=22547 .

Post Reply