Yes, such a query can be written, so no change to the ORM is required
for this.
However, this isn't the right mailing list for providing direct assistance.
If you need help constructing such a query, please visit one of the
appropriate support venues.
https://docs.djangoproject.com/en/3.1/faq/help/
<https://docs.djangoproject.com/en/3.1/faq/help/>
On 9/10/2021 3:08 PM, Mani Mozaffar wrote:
Hello,
Imagine this case:
Model A
——> Model B(many to many to A)
————-> Model C (many to many to B)
————-——->Model D (many to many to C)
To get a query set of objects D which are connected to an object like
A.id=1 , we can do a query like this:
Select * from A natural join B natural join C natural join D
Such a query does not exist as long as I have researched, so I think
Django ORM should be modified.
--
You received this message because you are subscribed to the Google
Groups "Django developers (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to django-developers+unsubscr...@googlegroups.com
<mailto:django-developers+unsubscr...@googlegroups.com>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-developers/cec2baa5-9c36-4151-80d0-eee555f1a977n%40googlegroups.com
<https://groups.google.com/d/msgid/django-developers/cec2baa5-9c36-4151-80d0-eee555f1a977n%40googlegroups.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google Groups "Django
developers (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-developers/061d86f7-c0af-d269-421f-eb99be8c1b75%40comcast.net.