Re: SQL Debug middleware

2007-04-22 Thread aaloy
2007/4/22, Honza Král <[EMAIL PROTECTED]>: > Hi, > try http://www.djangosnippets.org/snippets/93/ with the standard debug > context preprocessor shipped with django (see the snippet for how-to) > > it seems cleaner to add this to your base template than to hackishly > replace the tag. The use

SQL Debug middleware

2007-04-21 Thread Jesse Lovelace
Hey all, I made this the other day to help me track all the sql statements my pages were doing. I wanted something unobtrusive (i.e. middleware) and simple. Hope you like: from django.db import connection import re, pprint body_end = re.compile('', re.IGNORECASE) class