-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HasValue and != null incorrect translation to sql #2450
Comments
@toddtsic simple workaround could be to execute the projection on the client. It won't incur (much of) a perf hit since translation of joins and filter seem to be fine and therefore they can run on the server. However we should be doing a correct translation either way, so its definitely a bug. |
Thanks muamar, that's exactly what I did and yes it works just fine. Do you know if there are any estimates of specific ef components being available esp stored procedures. I have an important app that I want to deliver the second mvc6 go public, and this is probably the most important feature I'm missing right now. Lack of lazy loading turns out not to be much of a problem, it makes me code more efficiently, picking my joins and exact target fields. This issue here is also easily addressed... |
perhaps @rowanmiller and/or @divega can shed more light on the timelines & schedule |
We don't have a timeline to share for SPROC support. You can query from them using the new |
Thanks for the update Rowan. Is there an ETA on RTM and will the RTM advise Todd On Mon, Jun 29, 2015 at 10:51 AM, Rowan Miller [email protected]
|
@toddtsic I can't give you the dates as it is up to the ASP.NET team to announce them (I know they are working on publically sharing the schedule). You will be fine to use it in production. We won't be recommending EF7 as a general replacement for EF6 until we have sproc support etc. but production use will be fully supported as long as you are ok with the limitations. |
Hmm, I'm wondering whether I should insert EF 6x. Do you agree with the You need to manually set the connection string when creating the context so you can do this public class MyContext : DbContext { if you want to get the connection string from the config.json, then try this IConfiguration configuration = new and if you want to inject the context into the DI Container, then I added a public static class MyContextFactory{ and then added this in startup.cs services.AddTransient((a) => MyContextFactory.GetContext()); share http://stackoverflow.com/a/29572219/5019943edit On Mon, Jun 29, 2015 at 12:05 PM, Rowan Miller [email protected]
|
similar to #3703 |
I have a linq query that fails in sql because .HasValue or != null gets translated into IS NOT NULL rather than case statements.
This may reflect a misunderstanding on my part, but this seems to be the case.
linq query (note the fee_base, fee_discount, fee_latefee, those values can come from a team, and if not there the age group the team belongs to, and if not there the league the age group belongs to. This is a coalesce, or isnull scenario except that 0 is allowed so have to test, can't coalesce)
SQL SERVER 2014 sql translation:
The text was updated successfully, but these errors were encountered: