On Mon, 2009-05-11 at 12:09 -0700, lemming110 wrote:
[...]
> But using extra(select={'comment_count': sql,}) where
>
> sql = '''select count(*)
> from django_comments
> where django_comments.content_type_id=12 and
> django_comments.object_pk=
> %s'''
>
> gives me an error every way that I have t
Hey,
On Mon, May 11, 2009 at 9:09 PM, lemming110 wrote:
>
> I am trying to use the select keyword in extra. But I cannot properly
> quote the the expression for postrgres. I am using the
> django.contrib.comments. I started with this snippet
> http://www.djangosnippets.org/snippets/1101/ whic
I am trying to use the select keyword in extra. But I cannot properly
quote the the expression for postrgres. I am using the
django.contrib.comments. I started with this snippet
http://www.djangosnippets.org/snippets/1101/ which returns the number
of comments for an object. However, the code d
3 matches
Mail list logo