ORA-00904: "Extent1"."IsModified": invalid identifier,

ef-code-first entity-framework-6

Question

created CodeFirst classes using functional EDMX. I get this problem when I try to connect to the database. It's searching for a few columns that aren't there in the table. These columns are not included in the POCO and Fluent Mapping classes, either.

works with EDMX without a problem; Codefirst is the only problem

Why were the following columns added to the query? Are there any methods or properties that can prevent these columns from being included?

I receive the error below as a result.

An error occurred while executing the command definition. See the inner exception for details.
Inner Exception:ORA-00904: "Extent1"."IsModified": invalid identifier

    public TestContext() :
        base(GetDefaultConnection(), true)
    {
        Database.SetInitializer<TestContext>(null);

        this.Database.Log = Console.Write; 
        Configure();
    }


SELECT 
"Extent1".USERID,
"Extent1".FIRST_NAME,
"Extent1".LAST_NAME,
"Extent1".EMAIL_ADDRESS,
"Extent1".PHONE_NO,
"Extent1".FAX_NO,
"Extent1".ID,
"Extent1"."DisableEvent",
"Extent1"."RowNumberValue",
"Extent1"."IsNew",
"Extent1"."IsModified"
FROM USERS "Extent1"
WHERE (((UPPER("Extent1".USERID)) = :p__linq__0) OR ((UPPER("Extent1".USERID) IS NULL) AND (:p__linq__0 IS NULL))) AND ROWNUM <= 1
-- p__linq__0: 'SYSADM' (Type = String, Size = 6)
-- Executing at 3/11/2015 14:25:40 +05:30

columns below are not part of the table.

 "Extent1"."DisableEvent",
"Extent1"."RowNumberValue",
"Extent1"."IsNew",
"Extent1"."IsModified"
FROM USERS "Extent1" 
1
1
3/12/2015 12:42:32 PM

Popular Answer

I can infer from what I see that those rows are for the implementation of units of work (UOW).

In essence, RowNumberValue, IsNew, and IsModified are used for Paging. IsNew is used to denote an entity that was added, while IsModified is for an entity that is pending an update.

If the answer is still accurate, then ODP https://stackoverflow.com/a/23307234/79379 does not support ef6.

0
5/23/2017 12:07:46 PM


Related Questions





Related

Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow