Entity Mapping | @OneToOne, @OneToMany, @JoinColumn| Spring Data JPA | Spring Boot | Dev2Prod Coding

This video will focus on Entity Mapping in Spring Data JPA basic concept. Example to demonstrate use of @OneToOne, @OneToMany, @JoinColumn using Spring Boot.
Github:
github.com/Dev2ProdCoding/spr...
In case you like this video please Like, Subscribe & press the bell icon.
Dev2Prod Coding

Пікірлер: 96

  • @ushasharma2631
    @ushasharma26312 жыл бұрын

    Just because of your perfect solution and exact explanation instead of keeping it long you made it short. I am subscribing your channel. Good Efforts thank you :)

  • @dev2prodcoding

    @dev2prodcoding

    2 жыл бұрын

    Thanks and welcome

  • @jaymichalek1693
    @jaymichalek1693 Жыл бұрын

    Awesome explanation. I hope you can make more videos.

  • @karthickdk9313
    @karthickdk93132 жыл бұрын

    thank u so much.. upload more videos .. based on entity

  • @wantedlepota9960
    @wantedlepota9960 Жыл бұрын

    I like the fact that you have already created the classes(entity, controllers) before you record the video, which makes the video simple and short

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Thanks

  • @janstefangehrmann1139
    @janstefangehrmann11392 ай бұрын

    Thank you so much. Now I understand how to handle relations :)

  • @virendrasingh-en1yy
    @virendrasingh-en1yy Жыл бұрын

    nice explanation clear my all doubts with in short time thankyou so much

  • @siyansunny3090
    @siyansunny30902 жыл бұрын

    Good explanation.. waiting for next video...

  • @indranilganguly4750
    @indranilganguly4750 Жыл бұрын

    Great Video...Helped me a lot..Thanks

  • @abhiramnair2195
    @abhiramnair21952 жыл бұрын

    nice video..cleared all my doubts.thank you

  • @gauravsrivastava17
    @gauravsrivastava1719 күн бұрын

    Short and to the point 🔥🔥🔥🔥

  • @jakub.686
    @jakub.686 Жыл бұрын

    Thank You for this video, it helped me a lot

  • @harishchandra8057
    @harishchandra80572 жыл бұрын

    Nice explanation sir..

  • @tonycavanagh1929
    @tonycavanagh1929 Жыл бұрын

    Brilliant, well presented and consice.

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Thank you👍

  • @m_sharif
    @m_sharif Жыл бұрын

    Just to the point.. Thank you.

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    I am Glad you like it. Thanks!

  • @samnayakawadi
    @samnayakawadi2 жыл бұрын

    Subscribed. Thanks.

  • @swadeshswaroopbehera8465
    @swadeshswaroopbehera84652 жыл бұрын

    great explanation. keep up the good work.

  • @dev2prodcoding

    @dev2prodcoding

    2 жыл бұрын

    Thanks!

  • @neerajayarasani8456
    @neerajayarasani8456 Жыл бұрын

    short and clear. Thank you

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Glad it was helpful!

  • @shaharukhshaikh4676
    @shaharukhshaikh4676 Жыл бұрын

    No one beat this content on KZread thnks bro🎉

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Glad you enjoy it!

  • @jitendrapatil3276
    @jitendrapatil3276 Жыл бұрын

    Great Video. Just subscribed....

  • @zuberdiwan8123
    @zuberdiwan8123 Жыл бұрын

    Very Good Explained..Thank You.....

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Glad it was helpful!

  • @kosalamail9863
    @kosalamail9863 Жыл бұрын

    Perfect Explanation. Thanks

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Glad it was helpful!

  • @sproutboot
    @sproutboot Жыл бұрын

    I might sound stupid but I found it interesting that f.k @OneToOne private Address address, Employee class has a attribute of address which data type is Address, and it actually stores int value which is addressID? and by setting cascade.all, when we send request payload for saving emps, it will affect Address class and save address info on Address table. And the fk column in emp table will show just int value(AddrID). I learned a lot. and I hope I understand correctly. Thanks!

  • @manideepkumar959
    @manideepkumar9598 ай бұрын

    Bro, in address class , during 1-1 7:59 before and after using @OneToOne(mppedby="address") the output/table structure of address is same na, then can u tell me what is the use of that annotation

  • @Emanuel-yb3qk
    @Emanuel-yb3qk2 ай бұрын

    Thanks for explaning it too easy bro. Greetings from Mexico.

  • @dev2prodcoding

    @dev2prodcoding

    2 ай бұрын

    Glad it helped..Happy Learning!

  • @siddhantrakesh1245

    @siddhantrakesh1245

    2 ай бұрын

    ​@@dev2prodcoding bro i have one doubt

  • @connect2soumen
    @connect2soumen2 жыл бұрын

    Neat and clean video.

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Glad you liked it!

  • @user-zl9ub5hq4v
    @user-zl9ub5hq4v6 ай бұрын

    Thank u!

  • @dev2prodcoding

    @dev2prodcoding

    4 ай бұрын

    Thanks..

  • @kirindev
    @kirindev Жыл бұрын

    thank you

  • @thirumalyadav7509
    @thirumalyadav7509 Жыл бұрын

    Best explanation bro

  • @hrishikeshmukherjee8988
    @hrishikeshmukherjee89882 жыл бұрын

    wow

  • @suthar_ravi
    @suthar_ravi9 ай бұрын

    Great explanation 👌🏻😇

  • @dev2prodcoding

    @dev2prodcoding

    8 ай бұрын

    Glad you liked it!

  • @kotidinta1585
    @kotidinta15852 жыл бұрын

    Bro nice explaination. Could please make video on total spring project

  • @dev2prodcoding

    @dev2prodcoding

    2 жыл бұрын

    Sure

  • @Doum4n
    @Doum4n4 ай бұрын

    Thank you very much

  • @dev2prodcoding

    @dev2prodcoding

    3 ай бұрын

    You are welcome

  • @harishchandra8057
    @harishchandra80572 жыл бұрын

    plz upload the next part ...onetomany bidirectional and manytomany

  • @user-hm2mk1ql3l
    @user-hm2mk1ql3l Жыл бұрын

    So good explained! Just one question, first OneToOne Example, in Entity Employee_Detail you add Address address, which created automatically a FK fk_add_id, should a index be created to that fk_add_id, if data volumn is very big? Thank you!

  • @forinda
    @forinda Жыл бұрын

    Perfect explanation😊

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Thank you! 😃

  • @HimanshuVerma-ko7vr
    @HimanshuVerma-ko7vr Жыл бұрын

    very helpful

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Glad to hear that

  • @simon8284
    @simon82844 ай бұрын

    Sex bro Sex, even I couldn't understand this from Java Brains, Be Coder, and Code With Durgesh. You made a flawless victory...

  • @dev2prodcoding

    @dev2prodcoding

    3 ай бұрын

    Thank You!!

  • @atharvsingh6901
    @atharvsingh6901 Жыл бұрын

    Much appreciated dude🙂🙏

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Thanks...Happy to help

  • @HusnainAshfaq-kr5or
    @HusnainAshfaq-kr5orАй бұрын

    good

  • @ash416
    @ash416 Жыл бұрын

    Hello bro please reply I have to separate entities flight and airport and I don't want to save the data for airport while saving flight,since airport table is already populated Hope it make sense

  • @surajdevrajak9267
    @surajdevrajak9267 Жыл бұрын

    Good work man

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Thank you!

  • @HuieChannel
    @HuieChannel2 ай бұрын

    bro these indians are hella clutch

  • @pranshugautam8890
    @pranshugautam8890 Жыл бұрын

    I want to ask one q : when you used unidirectional you have not written one to one in address class and when you showed bidirectional then you write one-to-one in address class but there was no difference in output that you showed so why we have to write one-to-one in address class when there is no difference in output?

  • @donDan94

    @donDan94

    11 ай бұрын

    yeah right, I just watched the video and had the same question. Can I ask you, did you find any information about this, is there any difference? cheers!

  • @Rasmusorum
    @Rasmusorum Жыл бұрын

    How does it make sense to make a @onetoone relationship? Why not just embed the class?

  • @sonubandigi3788
    @sonubandigi378810 ай бұрын

    bro dhanyawad

  • @dev2prodcoding

    @dev2prodcoding

    10 ай бұрын

    Thank You!!

  • @ankushkamble911
    @ankushkamble911 Жыл бұрын

    Great Explanation bro...but one error is occuring actually when we run many to one first time it will save the data but if we add another member of same addresse it will update the data...that means fk_emp_id 1 will replace by 2 so...what to do plz help me

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Can you post your employee and address entity here for one to many mapping?

  • @wellingtonfjr
    @wellingtonfjr10 ай бұрын

    nice video!! +1 sub, thanks

  • @dev2prodcoding

    @dev2prodcoding

    10 ай бұрын

    Thanks for the sub!

  • @sachithnanayakkara4027
    @sachithnanayakkara40272 жыл бұрын

    How about One to Many & Many to One Mapping and also many to many mapping? Can you make a video for that

  • @dev2prodcoding

    @dev2prodcoding

    2 жыл бұрын

    kzread.info/dash/bejne/qGhkx5eMf7DMpLQ.html

  • @weixiangng8279
    @weixiangng82796 ай бұрын

    How to implement it with Angular though?

  • @Leo-fi6bg
    @Leo-fi6bg Жыл бұрын

    Hi bro .. how to configure my slq or post man in application properties.. will u please solve that

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    kzread.info/dash/bejne/Zat9tMVyZNPPhZs.html please check this video where I have explained how to configure DB using application.properties file. Code Link - > github.com/Dev2ProdCoding/spring-data-jpa-springboot/blob/master/src/main/resources/application.properties

  • @ayushkumarjajodia8828
    @ayushkumarjajodia88282 жыл бұрын

    what will be the difference in table structure b/w uni and bi direction of one to one mapping?

  • @dev2prodcoding

    @dev2prodcoding

    2 жыл бұрын

    There will be no difference.

  • @SKMishra2023
    @SKMishra20232 жыл бұрын

    8:12

  • @roshanpawar571
    @roshanpawar5712 жыл бұрын

    Nice video..... but how to update mapping data

  • @dev2prodcoding

    @dev2prodcoding

    2 жыл бұрын

    Thanks @roshan....I am assuming by update mapping data you mean updating records in db. For updating you can use same method you used to save it i.e saveAll() or save(). Let me know in case of any other query.

  • @venkateshejjigiri-4137
    @venkateshejjigiri-413711 ай бұрын

    fk_add_id is not reflecting in employee table. and no data in adreess table. pls help me

  • @KlanBr1
    @KlanBr110 ай бұрын

    if i duplicate my request in postman, so duplicate my entities, that not shoul be happen, because then i have duplicate employees and addresses, how do yo stop this behavior, you put some logical in your service?(sorry for my english)

  • @vinaymathapati4077
    @vinaymathapati4077 Жыл бұрын

    Where is properties file

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    github.com/Dev2ProdCoding/spring-data-jpa-mappings/tree/master/src/main/resources

  • @dod-do-or-dont
    @dod-do-or-dont2 ай бұрын

    Why 90% od tutorials are low quality indian ones?

  • @siddhantrakesh1245

    @siddhantrakesh1245

    2 ай бұрын

    Bro i have one doubt

  • @kandruvinay6736
    @kandruvinay67362 жыл бұрын

    Push the file to git

  • @dev2prodcoding

    @dev2prodcoding

    2 жыл бұрын

    url : github.com/Dev2ProdCoding/spring-data-jpa-mappings.git

  • @tobyhamilton2153
    @tobyhamilton2153 Жыл бұрын

    You didn't even show how to right at the get mapping, so you just showed how to do the annotations, how is someone meant to known how to make the get request!!!

  • @venu5791
    @venu5791 Жыл бұрын

    can you add @jsonbackReference, @jsonmanagedreference along with the mappings

  • @nguyenquangtinh4911
    @nguyenquangtinh4911 Жыл бұрын

    thank you

  • @dev2prodcoding

    @dev2prodcoding

    Жыл бұрын

    Welcome!

Келесі