Re: "Normalized" Data type for __month and __day lookups?

2009-01-19 Thread Malcolm Tredinnick
On Tue, 2009-01-20 at 02:16 -0300, Leo Soto M. wrote: [...] > I spent around an hour digging in the history of that code, and come > to the following reasoning: the problems were caused by two mismatches > between what the backend expected and what it got: > > - After the get_db_prep_*

Re: "Normalized" Data type for __month and __day lookups?

2009-01-19 Thread Leo Soto M.
On Tue, Jan 20, 2009 at 2:02 AM, Malcolm Tredinnick wrote: > > On Tue, 2009-01-20 at 01:54 -0300, Leo Soto M. wrote: > [...] >> So I've uploaded a small patch on #10071[4] which does the >> normalization to int instead of unicode. I tested it with sqlite >> (which was

Re: "Normalized" Data type for __month and __day lookups?

2009-01-19 Thread Malcolm Tredinnick
On Tue, 2009-01-20 at 01:54 -0300, Leo Soto M. wrote: [...] > So I've uploaded a small patch on #10071[4] which does the > normalization to int instead of unicode. I tested it with sqlite > (which was the problematic backend) and it doesn't break any test. > > Now, my questions are: > > - Is

"Normalized" Data type for __month and __day lookups?

2009-01-19 Thread Leo Soto M.
While resuming the Django/Jython work, I've been hit by a small inconsistency on the types of lookup arguments, as received by DB backends. Basically, __year lookup arguments are converted to integers before being passed to the backend, but for __month and __day it's unicode. That's weird. And