12👍
✅
In Django 1.1, QuerySet.query
returned a BaseQuery
object, now it returns a Query
objects. The query object has a __str__
method defined that returns the SQL.
👤Zach
4👍
as answered in In django 1.2.1 how can I get something like the old .as_sql?
it’s just:
print QuerySet.query
Source:stackexchange.com