Using stored procedure in entity framework core

Поделиться
HTML-код
  • Опубликовано: 4 окт 2024

Комментарии • 28

  • @martink4975
    @martink4975 4 года назад +7

    Amazing video, I am kinda scared of using EF core , i hear its a noob trap even though its an amazing tool. Its easy to use when it works but when it breaks or slows down hard to fix. I hope you continue to make in-depth EF core vids so that the people have more control over what EF core dose and doesn't auto generate someone straight to debug hell. Thx again @
    kudvenkat i am gonna go and make some stored procedures now :D

  • @coolwaterdvr
    @coolwaterdvr 4 года назад

    I'm so happy. In my work we only use stored procedures. Thank you very much Venkat . 👍👍👍👍👍

  • @abeldaniel2245
    @abeldaniel2245 4 года назад

    You make everything simple and to the point.Thank you.

  • @zeeshanahmadkhalil8920
    @zeeshanahmadkhalil8920 4 года назад +4

    what if my store procedure contains joins? In this video, we are executing stores procedure inside Employees Table. How we will execute a store procedure which is fetching data from two joined tables?

    • @AryaChuodhury
      @AryaChuodhury 3 года назад

      Recently i had a issue of multiple result set i found simple ado.net with some extension method solves the problem.

  • @ernstpeterlegrand
    @ernstpeterlegrand 4 года назад +3

    Very nice. Did something rather similar. When you have a sp for a join query then I make another model class that represents this join. So, I actually end up with a lot of model classes just to match the results of the stored procedure. So far didn't know a better way. Any suggestions?

  • @AlishSafarli
    @AlishSafarli 3 года назад +1

    what if I have a pretty much expensive sp query? I should set it to a string variable as well?

  • @ameernajath3613
    @ameernajath3613 Год назад

    Just Perect ! 👍👍

  • @johandemu3658
    @johandemu3658 3 года назад

    Helpful, thanks..

  • @xmesaj2
    @xmesaj2 4 года назад

    Worth noting, that it's better to select P type object from sysobjects with the procedure name to avoid conflicts if for some reason you create procedure with database-first approach and forgot to drop it to make the migration actually drop it when already exists.
    IF (OBJECT_ID('spGetEmployeeById', 'P') IS NOT NULL)
    DROP PROCEDURE spGetEmployeeById
    GO

  • @Jiz39
    @Jiz39 4 года назад

    your tutorials are amazing always.
    but in ur video..i dint found what i want... i thought i would get a good explanation about CRUD Operations using Stored Procedure in Sql Server. ASP.Net Core Web Api Without Entity Framework but Using 3 layered Architecture .(without Presentation Layer) Applies Dependency Injection.
    Thank You!

  • @NeonEnigmaJC
    @NeonEnigmaJC 4 года назад

    What if you already have an existing stored procedure in the database. Do you still need to migrate it and go through the whole thing?

  • @lazarstevanovic1286
    @lazarstevanovic1286 4 года назад

    Thank youu so much for this video!!

  • @80amnesia
    @80amnesia 3 года назад

    Thanks Venkat!!

  • @karvan101
    @karvan101 2 года назад

    Why did you create a procedure while you can access the same result easily with the help of EF core
    Can you show the same thing with multiple table columns selection???

  • @coolwaterdvr
    @coolwaterdvr 4 года назад

    Thanks Venkat. 👍👍👍👍👍

  • @ranasohel8645
    @ranasohel8645 4 года назад

    Thank You sir. Would you please give me an example dbfirst approach and is there any code in how we can make only a method for calling all the store procedure with various types of parameters.

  • @fitpacking8790
    @fitpacking8790 2 года назад

    Why does EF core require you to use context.Employees? If you had 2nd table, say Customers, could you use context.Customers.FromSqlRaw("spGetEmployeeById {}", id) instead of context.Employees.FromSqlRaw("spGetEmployeeById {}", id)?
    It seems to me that the stored procedure is independent of the table name. In this case, I see it's related but how would EF core know this ?

  • @manipathak4296
    @manipathak4296 4 года назад

    Hello sir, I am struggling a bit about how to use crud stored procedure in entity framework core for legacy applications (database first approch).

  • @dempseyroll96
    @dempseyroll96 2 года назад

    My tutors told two things which are not matching with this video:-
    First : Stored Procs can't do SELECT operations
    Second: In EF Core,we use ExecuteSqlRaw to implement stored proc

  • @AshishSingh146
    @AshishSingh146 3 года назад

    HI, how to return multiple result set from stored procedures with entity framework core

  • @aaryandangol4756
    @aaryandangol4756 4 года назад

    Thank you Sir.I am having error while executing stored procedure with output parameters in oracle database. please give me some solution sir.

  • @deepakampli542
    @deepakampli542 4 года назад

    Is it possible to makevideo on postgres server and make calls to stored procedures with code first approach

  • @sakthir3892
    @sakthir3892 4 года назад

    Thanks Sir....

  • @STUPIDYOUTUBE_HIDINGMSGS
    @STUPIDYOUTUBE_HIDINGMSGS 2 года назад

    Great tutorial as always!

  • @microtech2448
    @microtech2448 4 года назад

    That's insane how SPs are called in code first, we have to hard code its name and remember parameter positions which is error prone. I am big fan of how sps are called as methods with intellisence support in database approaches. Hate few things of Microsoft the way they do those.

  • @andrewfrank7222
    @andrewfrank7222 2 года назад

    Thumbs down for forced ad watching.