Hi guys, After asking this question on django-users:
https://groups.google.com/forum/#!topic/django-users/EuPduHjSNos And in several other forums, and not finding a solution, I've reached a conclusion: It would be really helpful to allow batching SQL queries in Django. I should preface by saying I'm not very good at SQL and I don't know how the ORM works exactly, so maybe what I'm saying is wrong in some way, if so please correct me. I know Django already support bulk insertion, but what I want is to make multiple SQL reads, of various kinds, and have them populate multiple model instances. This is important for lowering the number of database roundtrips that Django does. I gave one example for when this need arises in the above link; another example is how on every request, Django fetches the session, it then parses the session, looks for the user ID, and then fetches the user. This is a waste. If Django could do a combined query that fetches both the session and the user in SQL, this would be best. I'm not good at SQL, so I'm not sure whether it can be done. But that's just one example of where you can save a roundtrip to the database. Am I right that Django doesn't currently let you do that? Do you think it's possible to make Django do that? Thanks, Ram. -- 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 post to this group, send email to django-developers@googlegroups.com. Visit this group at http://groups.google.com/group/django-developers. To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/d111bd3b-3ca7-426d-83a1-047e9f56c641%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.