How to call Stored Procedure in Entity Framework 6 (Code-First)?

You can call a stored procedure in your DbContext class as follows.

this.Database.SqlQuery<YourEntityType>("storedProcedureName",params);

But if your stored procedure returns multiple result sets as your sample code, then you can see this helpful article on MSDN

Stored Procedures with Multiple Result Sets

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)