Django Model Inheritance Options Introduction - ORM Part-9

  Рет қаралды 22,060

Very Academy

Very Academy

Күн бұрын

Пікірлер: 36
@hamzadlm6625
@hamzadlm6625 2 жыл бұрын
You are a God, literally making my life easier, most concise, on point, well established tutorials out there
@veryacademy
@veryacademy 2 жыл бұрын
Thanks!
@elias-earaujo
@elias-earaujo 2 жыл бұрын
excellent content! I really needed to learn this! Thanks! Greetings from Brazil!
@bekzodnegmatillaev7528
@bekzodnegmatillaev7528 4 жыл бұрын
Best django channel out there
@veryacademy
@veryacademy 4 жыл бұрын
Thank you Bekzod - I will keep trying to make better content for you all
@andromeda_yt_
@andromeda_yt_ 3 жыл бұрын
Hello. This is such a wonderful series! You make some of the best coding tutorials out there, thanks!
@veryacademy
@veryacademy 3 жыл бұрын
Andromeda, thank you - really appreciated.
@arbaaz9194
@arbaaz9194 4 жыл бұрын
Very cool and descriptive tutorial among very few. A bright future is coming. Wish you all the best and thank you for the tut.
@veryacademy
@veryacademy 4 жыл бұрын
Thanks Arbaaz, as long as it is useful to someone I will carry on making tutorials regardless of the future prospects 👍
@semantic_error
@semantic_error 4 жыл бұрын
Thank you very much for this video series. It is really the best series on Django ORM.
@veryacademy
@veryacademy 4 жыл бұрын
Glad you enjoy it! Once I get back setup with recording I will improve upon it and add some more
@HemantSahu-kj2qb
@HemantSahu-kj2qb 2 жыл бұрын
Thank you for making these videos. You have made such complex topic easy to understand
@nurmukhammad_30k
@nurmukhammad_30k 2 жыл бұрын
Super appreciating this video
@tochimclaren
@tochimclaren 4 жыл бұрын
Thanks! Nice tutorials, I hope to start my channel someday. Many thanks for your work.
@veryacademy
@veryacademy 4 жыл бұрын
Best of luck!
@Horen_Usuf
@Horen_Usuf Жыл бұрын
Thanks, can I have the link for all the series
@Shivam_Manswalia
@Shivam_Manswalia 3 жыл бұрын
So while making migrations it didn't created a table for base class why??
@veryacademy
@veryacademy 3 жыл бұрын
class Publishable(models.Model): title = models.CharField(...) date = models.DateField(....) class Meta: abstract = True If for example you set the meta to abstract - any other tables using this abstract class will copy title and data to that class - this table Publishable will not be created. A benefit is that it is a way of creating fields that would be replicated in multiple tables - saving you having to write these fields out multiple times
@manishranjan9982
@manishranjan9982 3 жыл бұрын
For class A it has meta derived from BaseMeta so why don't A is also abstract=True?
@veryacademy
@veryacademy 3 жыл бұрын
Hi, I cant remember what is in the video but - key here is that abstract=True on a model will mean that it is not actually created in the database - all over classes or models connected will just inherit (make a copy of) the fields. If you dont use abstract true all models are created in the database
@georgesmith3022
@georgesmith3022 4 жыл бұрын
So if I want to have different types of users, each with different fields, for instance Students and Teachers, should I choose a User model and inherit from there? or should I create a different Profile for each and use a onetoone relationship with the user model?
@veryacademy
@veryacademy 4 жыл бұрын
Good question - how about 1 user table and additional tables for students and teachers 1to1
@kiorepaul6278
@kiorepaul6278 4 жыл бұрын
Hi again. Thanks for making such great lecture series. I felt you should have covered queries involving related_name. And are you planning on a series on orm/sql queries optimisation i.e how to minimise number of db queries?
@dh1ao
@dh1ao 4 жыл бұрын
Thanks for all your work. Is there a chance of a video regarding array/lists in ORM Django models besides postgres?
@veryacademy
@veryacademy 4 жыл бұрын
Sure there is - what exactly were you thinking? This could mean many things - array/lists in ORM Django models besides postgres?
@dh1ao
@dh1ao 4 жыл бұрын
@@veryacademy I would like to store an array of Python objects in a sql database other than postgres. For postgres there is a model.array_field. Maybe a json serializer could do a similar job for let's say mysql? Thanks for reading
@KevinTempelx
@KevinTempelx 4 жыл бұрын
Thank you!!
@veryacademy
@veryacademy 4 жыл бұрын
You're welcome!
@AhmedTheCoder
@AhmedTheCoder 4 жыл бұрын
What if I have three types of reports( daily, weekly, monthly) Different fields, they are have common relationship with two models (staff, machines) That have lot of fields, I want to make a relation between these models, can I use inherited models, or foreign keys? Help!
@pallyweb
@pallyweb 4 жыл бұрын
Hi bro, In your tutorials VS Code provides very good IntelliSense . However , I am unable to get much out of VS Code for Django/Python IntelliSense . Kindly help in this regard. Thanks :)
@veryacademy
@veryacademy 4 жыл бұрын
code.visualstudio.com/docs/languages/python
@pallyweb
@pallyweb 4 жыл бұрын
@@veryacademy Thanks :)
@sambad8429
@sambad8429 2 жыл бұрын
the proxy model part is very incomplete
@veryacademy
@veryacademy 2 жыл бұрын
Thanks Samba, at the time it met the needs of what I needed. I will no doubt come around on this again in the future
@rezarostami891
@rezarostami891 4 жыл бұрын
very good
@veryacademy
@veryacademy 4 жыл бұрын
Thank you! Cheers!
Django bypass ORM! - Performing raw SQL queries without the ORM
11:57
How to treat Acne💉
00:31
ISSEI / いっせい
Рет қаралды 108 МЛН
Cat mode and a glass of water #family #humor #fun
00:22
Kotiki_Z
Рет қаралды 42 МЛН
Python Django Inheritance Optimisation Exercise
52:56
Very Academy
Рет қаралды 13 М.
How to use annotate and aggregate on Django querysets
15:13
Solving one of PostgreSQL's biggest weaknesses.
17:12
Dreams of Code
Рет қаралды 227 М.
Learn the basics of Django's Model Managers and Querysets
19:38
Matt Freire
Рет қаралды 45 М.
10 Signs Your Software Project Is Heading For FAILURE
17:59
Continuous Delivery
Рет қаралды 41 М.
Django OR query
22:09
Very Academy
Рет қаралды 41 М.
This Is Why Python Data Classes Are Awesome
22:19
ArjanCodes
Рет қаралды 825 М.
OOP Class Inheritance and Private Class Members - Python for Beginners!
16:12
How to treat Acne💉
00:31
ISSEI / いっせい
Рет қаралды 108 МЛН