Code First support for stored procedures
EF 4.1 doesn't support stored procedures in code-first:
EF6 includes stored procedure support in code first for CUD operations. Support for function imports for reads was originally postponed but currently isn’t planned as a future improvement.
Note that EF Core still does not include stored procedure mapping yet.
David McClelland commented
Code-First support for function imports (for reads) is the thing we are waiting for to be ready to move to EF from Linq to SQL :-)
Reverse Engineer Code First - Would like to be able to generate the stored procedure wrappers.
Thanks. Looking forward to it
Mike Bishop commented
Depends on what you mean be "support". You can still call stored procedures via context.Database.SqlQuery and context.Database.ExecuteSqlCommand
Yea, I wrote it. commented
for support for stored procedures in EF 4.1 (aka Code First).
Robert Slaney commented
This is stopping us migrate from Linq-to-Sql
Also, map defaults on stored procedures parameters to optional parameters when code generating for .NET 4.0
Marcel Veldhuizen commented
Very similar: support for User Defined Functions (UDF) while you're at it :)
I really miss this feature of the model first approach.
Please please I really need stored procedure support in code first asap