Changeset 5243
- Timestamp:
- 05/14/07 16:58:01 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
django/branches/unicode/tests/modeltests/many_to_one/models.py
r5185 r5243 155 155 [<Article: John's second story>, <Article: This is a test>] 156 156 157 # And should work fine with the unicode that comes out of 158 # newforms.Form.cleaned_data 159 >>> Article.objects.filter(reporter__first_name__exact='John').extra(where=["many_to_one_article__reporter.last_name='%s'" % u'Smith']) 160 [<Article: John's second story>, <Article: This is a test>] 161 157 162 # Find all Articles for the Reporter whose ID is 1. 158 # Use direct ID check, pk check, and object comparison 163 # Use direct ID check, pk check, and object comparison 159 164 >>> Article.objects.filter(reporter__id__exact=1) 160 165 [<Article: John's second story>, <Article: This is a test>]
