mvc stored procedure

Need two extremely simple sample

1. Call stored procedure in MVC 3 without using Entity Frame work.
2. Call stored procedure in MVC 3 using Entity Frame work

3. Any other tools that I can use to call stored procedure in MVC style environment.

Who is Participating?
guru_samiConnect With a Mentor Commented:
EF with StoreProcedure is Data First concept. Here is a great site for all EF stuff.
Craig WagnerSoftware ArchitectCommented:
This question has nothing to do with MVC. Calling a stored procedure is done the same way whether it is ASP.NET WebForms, ASP.NET MVC, WinForms, WPF, etc, etc.

Here's how to do it without EF.

To call it with EF you need to create an entity data model, import the stored procedure, and add a new function import. Once you've done that the stored procedure appears as a method on the context.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.