Laravel 8 tutorial - Save Data in Database

Sdílet
Vložit
  • čas přidán 16. 09. 2020
  • In this laravel 8 and 9 video tutorial, we learn how to save data in database pagination in a simple way. This video is made by anil Sidhu in the English language.
    steps of video
    Make HTML form in view
    Make Model
    Make Controller
    Make routes
    save data in db
    check and is saved on not
    Interview Question over Model
    Latest laravel tutorial with version 9
    laravel 9 tutorial
    laravel 9 playlist • Laravel 9 tutorial

Komentáře • 67

  • @codestepbystep
    @codestepbystep  Před 2 lety +7

    Please support me by subscribe, like and comment :) thank you

  • @ainguyenxuan4726
    @ainguyenxuan4726 Před 3 lety

    I'm from Vietnam, I thank you so much for these useful videos

  • @majdalin1265
    @majdalin1265 Před 11 měsíci

    the best instructor the best tutorial Thanks a lot .love u❤

  • @ashokbishwas
    @ashokbishwas Před rokem +1

    i have repeated this video for 5 times for practice and to sharpen skill on laravel, If you come to Kathmandu to visit Pashupatinath, I will host you. God bless you brother.

  • @NareshKumar-xf6rl
    @NareshKumar-xf6rl Před 3 lety +22

    We can save data into two tables with the help of one model by using eloquent relationships.

  • @devranjankumar988
    @devranjankumar988 Před 2 lety

    U saved my life bro..

  • @fatimealbatat1183
    @fatimealbatat1183 Před 2 lety

    thank you sooo much, worked for me :)

  • @omkarmodak802
    @omkarmodak802 Před 3 lety

    You saved me. Thanks

  • @goldenvillains3611
    @goldenvillains3611 Před 2 lety +1

    Thanks chief, this saved me a lot of stress!

  • @jammincoder
    @jammincoder Před 2 lety +1

    That's really cool, man! Helped me out a ton, thanks!!

  • @hamidoahmed9985
    @hamidoahmed9985 Před 11 měsíci

    thanks bro, you're the best

  • @khushbuwaghela2986
    @khushbuwaghela2986 Před 3 lety

    while i m import model after write code of controller...it is just loading and loading nothing gonna happen, no error no output.. what i have to do....i m using laravel 8

  • @xXTheSalvationXx
    @xXTheSalvationXx Před 3 lety

    Thank you, this helped alot!

  • @lenwoperlenwoper2222
    @lenwoperlenwoper2222 Před 2 lety

    thanks a lot ❤️ 🔥🔥

  • @nooralalem6099
    @nooralalem6099 Před 3 lety

    THANK YOU :)

  • @kailasmokhare9990
    @kailasmokhare9990 Před 3 lety

    Thank you....

  • @Niset_IT
    @Niset_IT Před rokem +1

    The best tutorial in the world :) Thanks

  • @gueilletoumaihissein727
    @gueilletoumaihissein727 Před rokem +1

    Well done

  • @lasithadulshan7357
    @lasithadulshan7357 Před 3 lety

    we can create two functions to save data in two tables

  • @subhodeepbhattacharjee9569

    Hello, In CI We write all kind database related code in model. But In Laraval we just create model and define table names only write all code in my controller.... So, Please explain me what kind of functions that we write in my model. and create a simple project with all existing files....

  • @JasvirSingh-fd6fp
    @JasvirSingh-fd6fp Před 3 lety +7

    actually we should not use One model for two or more tables, each model is specified for that particular table, its unnecessary thing. each table has and should have its own Model.

    • @ultimate-acs7868
      @ultimate-acs7868 Před 3 lety +2

      Oh...But what if we need to use joins on the table where there is an interaction of 2 or more tables?

    • @hanjoyitsu1414
      @hanjoyitsu1414 Před 3 lety

      ^ What Ultimate-ACs said. or idk. im a newbie prorammer, is it necessary to make them in the same file to join the table?

  • @user-xc4lj2up5m
    @user-xc4lj2up5m Před 11 měsíci

    Thanks a lot

  • @muhammadwaseem9489
    @muhammadwaseem9489 Před 3 lety +1

    bro..after putting values in the input fields...the submitt button is not going on any page (means to say submiit button is not working not submitting values the what is the error occur ....) please guide

  • @dhainik.suthar
    @dhainik.suthar Před 3 lety +1

    sir what if we have non required
    input field. it give us error how to solve it ?

    • @rifatbinmonsur1492
      @rifatbinmonsur1492 Před 2 lety

      can add default value in the input field in mySql database, should solve the issue. (localhost/phpmyadmin -> your database table -> structure -> edit the field -> default value-> NULL)

  • @kgethegodev
    @kgethegodev Před 2 lety

    How would you authentiate this table on login

  • @noor-ul-sabahafeez5543

    how can add data using foriegn key ?

  • @vanitachaudhari1132
    @vanitachaudhari1132 Před 3 lety

    hey but i am not able to run $ member->save(); it is giving me error....
    array_key_exists(): The first argument should be either a string or an integer...
    it giving me this error .... i hope u solve this

    • @kevalbhanderi594
      @kevalbhanderi594 Před 3 lety

      you have to specify your first argument in the database table when you created it.

  • @bonamariecapao4527
    @bonamariecapao4527 Před 3 lety +2

    hello, I just can't seem to insert data into my database, can you please tell me why? I'm using laravel 8

  • @traglesofrware6293
    @traglesofrware6293 Před rokem

    sir ye error aa rha hai "message": "Method App\\Http\\Controllers\\TeacherController::save does not exist.",

  • @lekhnibhatnagar6738
    @lekhnibhatnagar6738 Před 3 lety

    I am getting and error---> Trait 'App\HasFactory' not found what to do now and in Eloquent folder i have only factory.php not factories? how to solve it , i am using laravel 8 . I followed every step still not able to insert data. plzz help

    • @abhinavsingh7859
      @abhinavsingh7859 Před 3 lety +1

      Add use HasFactory; in the model under the member class

    • @abhinavsingh7859
      @abhinavsingh7859 Před 3 lety +1

      Btw did your project was installed properly with no errors?

    • @lekhnibhatnagar6738
      @lekhnibhatnagar6738 Před 3 lety

      @@abhinavsingh7859 yes abhinav my project was installed properly..do you think there is an issue in the installation?

    • @abhinavsingh7859
      @abhinavsingh7859 Před 3 lety +1

      Yes i think....if you are following every steps properly then may be there might be a issue that you didn't set it up properly....it happens to me most of the time...did you added that one line in the model....?

    • @lekhnibhatnagar6738
      @lekhnibhatnagar6738 Před 3 lety +1

      @@abhinavsingh7859 yes I did added the model and followed every step...but i tried another way and was able to insert data into my db.. anyway thanks lot for the help.🌻

  • @rutvikdahima438
    @rutvikdahima438 Před 3 lety

    sub video hindi mai banaye ye kyu english mai ?

  • @raghavendrakesari337
    @raghavendrakesari337 Před 3 lety

    bhai bs ab bta do donation kaha karna hai??????????????????????????????

  • @Umair-Sid47
    @Umair-Sid47 Před 3 lety

    Title apney Hindi diya howa he or parha English me rhy ho ap
    thats not fair.

  • @laibagillani2905
    @laibagillani2905 Před 3 lety +1

    its giving me null response

  • @faheemfalan9137
    @faheemfalan9137 Před 2 lety

    Save data with migration

  • @saikumarkandikonda431
    @saikumarkandikonda431 Před 3 lety

    using hasmany relationship we can insert into mutliple tables

  • @JamesAutoDude
    @JamesAutoDude Před 11 měsíci

    Why are you making your own methods? It should use the create, store, edit, update methods...

  • @navinsahanivlog
    @navinsahanivlog Před 3 lety

    jab sare video hindi translate kiye to ye video to english me krne ka

  • @pratikshalihinar4225
    @pratikshalihinar4225 Před 3 lety

    After entering data page is expired

  • @danilotrix
    @danilotrix Před rokem

    Can you do in the model:
    $member = new Member;
    $member = $req;
    Instead of saving all the values one by one?
    Thanks

  • @Umair-Sid47
    @Umair-Sid47 Před 3 lety

    yrrr ye kya chawal mari he apney... shuru waley topics hindi me or main topiucs english me..axhi bhali samjh arhi thi ab me kesay carry on kru ye
    course apka

  • @ryansalem9920
    @ryansalem9920 Před rokem

    Hello man , just have one question , does it mean that every table must have 1 model file ? for example
    table1
    table2
    table3
    should i create three models ?
    so that i can put on every file
    public $table = "table1";
    public $table = "table2";
    public $table = "table3";
    Thank you my friend.