

def date_trunc_sql(self, lookup_type, field_name):
    return ("DATE_TRUNC('%s', %s)" % (lookup_type, field_name))

dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.2/django/db/backends/postgresql/operations.py DatabaseOperations.date_trunc_sql/original