Re: [Django] #14110: iexact lookup doesn't work with subquery values

2010-12-03 Thread Django
#14110: iexact lookup doesn't work with subquery values
---+
  Reporter:  Suor  | Owner:  Suor   
  
Status:  closed| Milestone: 
  
 Component:  Database layer (models, ORM)  |   Version:  1.2
  
Resolution:  wontfix   |  Keywords:  
sprintdec2010
 Stage:  Unreviewed| Has_patch:  1  
  
Needs_docs:  0 |   Needs_tests:  0  
  
Needs_better_patch:  0 |  
---+
Changes (by aweakley):

  * keywords:  => sprintdec2010
  * status:  new => closed
  * resolution:  => wontfix

Comment:

 I ran this past Russ.
 This seems like very much an edge case, relying on the fact that a one-
 item values result could be interpreted as a string.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-upda...@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



Re: [Django] #14110: iexact lookup doesn't work with subquery values

2010-08-14 Thread Django
#14110: iexact lookup doesn't work with subquery values
---+
  Reporter:  Suor  | Owner:  Suor
Status:  new   | Milestone:  
 Component:  Database layer (models, ORM)  |   Version:  1.2 
Resolution:|  Keywords:  
 Stage:  Unreviewed| Has_patch:  1   
Needs_docs:  0 |   Needs_tests:  0   
Needs_better_patch:  0 |  
---+
Changes (by Suor):

  * needs_better_patch:  => 0
  * needs_tests:  => 0
  * needs_docs:  => 0

Comment:

 P.S. supplied patch doesn't make it right for icontains but it will do for
 iexact for postgre and many lookups for oracle.[[BR]]

 Also, current code assume that connection.operators[lookup] will end with
 %s which is wrong.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-upda...@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.



[Django] #14110: iexact lookup doesn't work with subquery values

2010-08-14 Thread Django
#14110: iexact lookup doesn't work with subquery values
--+-
 Reporter:  Suor  |   Owner:  Suor  
   Status:  new   |   Milestone:
Component:  Database layer (models, ORM)  | Version:  1.2   
 Keywords:|   Stage:  Unreviewed
Has_patch:  1 |  
--+-
 With PostgreSQL and model
 {{{
 class Category(models.Model):
 title = models.CharField(max_length=127)

 }}}
 we have:
 {{{
 >>>
 
Category.objects.filter(title__icontains=Category.objects.filter(pk=1).values('title'))
 DatabaseError: syntax error at or near "("
 LINE 1: ...PPER("board_category"."title"::text) LIKE UPPER() (SELECT U0...

 >>> print connection.queries[-1]['sql']
 SELECT "app_category"."id", "app_category"."title" FROM "app_category"
 WHERE UPPER("app_category"."title"::text)
 LIKE UPPER() (SELECT U0."title" FROM "app_category" U0 WHERE U0."id" = 1 )
 }}}

 problem with every lookup for which %s is in the middle of
 connection.operators[lookup]

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-upda...@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.