﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
28574	Add a QuerySet.explain() method	Tom Forbes	Tom Forbes	"When diagnosing slow queries it would be handy to have an `explain` method on the queryset. Currently if you have a queryset that is performing slowly and you want to use your databases EXPLAIN query to see why, you have to print the querysets query attribute, copy and paste the often verbose string into a database shell, add the appropriate explain syntax, fix any parameters that may be missing and execute it. This can be quite annoying.

Every database that is supported in core supports this, usually by adding `EXPLAIN` before the query. Simply returning whatever the database gives you (which is vastly different per vendor and even version) could be a good improvement.

"	New feature	closed	Database layer (models, ORM)	dev	Normal	fixed		Tom Forbes	Ready for checkin	1	0	0	0	0	0
