Problems with .NET 4.5, Entity Framework and Oracle

2.3k views Asked by At

I am working on an application (let's call it A, an ASP.NET MVC3 web site) in .NET 4.0, under Visual Studio 2010 and with Entity Framework and Oracle. Everything goes right.

For an other application (let's call it B), I installed Visual Studio 2012, which installed the new version of the .NET framework. Since, I can not get A working right.

The error I get is : Oracle 11.2.0.3.0 does not support APPLY

I've made some digging and I found a solution : uninstall the .NET framework 4.5 when I need to work on A, and install it back when I need to work on B. This is not very
satisfactory.

It looks like Oracle did not succeed to translate the EF query into an Oracle query. But why ? I still target the same version of the .NET framework (4.0) ...

I am currently trying different ODAC version in order to see if the problem could come from an incompatibility between ODAC and the new version of .NET.

Do you have any other idea of what could cause that and how to fix it ?

Thank you !

Sorry for my english, I am not a native speaker.

1

There are 1 answers

10
Pawel On

Oracle does not support CROSS/OUTER APPLY and some queries generated by EF require these operators. See this and this for more details

Having said that - as per the comments there seems to be a regression in EF5/.NET Framework 4.5 where EF started creating Apply nodes in queries for which Apply nodes were not created in EF4. It was previously investigated but apparently this scenario was not covered.

This regression was actually fixed in EF6 (which is probably not extremely helpful since currently there is no Oracle EF6 provider (at least not from Oracle) at this point)