Getting data from Stored procedure that returns multiple result sets using Entity Framework in MVC RRS feed

  • Question

  • User-173333858 posted

    I am rebuilding a project in MVC using Entity Framework, which was originally built using web forms. One of the pages needs 'Employee Details' that are spread over 5 sub tables that a stored procedure returns. I am using Entity Framework for views. Is it possible to use the same stored procedure with EF? Can someone provide a link that explains how to do this. So far I have been able to get data from a SP that returns a single dataset. But a SP that uses multiple tables and returns multiple subsets using EF seems to want a different way. Let me know. Thanks!

    Friday, March 5, 2021 9:35 PM


  • User475983607 posted

    EF can return a single result set.  If you want to return multiple results sets then use ADO.NET.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, March 5, 2021 9:54 PM

All replies