django-debug-toolbar/django-debug-toolbar — pull request #264 by webjunkie (2012-02-22 08:17:20+00:00)
Title: SQL panel collapses query with multiple SELECT...FROM wrong

The regex should not match greedy, otherwise a query with multiple "SELECT... FROM" statements is going to get unreadable. This patch fixes it and works nice with longer, nested SQL statements.