I'll be happy to. I did put in a track item for this (although I can't remember what the number is). I'm using PostgreSQL 8.1 The models are at: http://paste.e-scribe.com/1125/ This is actually a combination of two related errors: One that leads to a searching error (?e=1) and another that leads to a ProgrammingError (identified in the track item) Here is the scenario: 1. Foreign Key in the ordering 2. Foreign Key is not a typical "id" key (using primary_key=True) (I'm assuming this, BTW) If the Foreign key IS IN the search_fields, everything will return and you will see a ?e=1 in the query string of the results. If the Foreign key IS NOT IN the search_fields, you will get a ProgrammingError, missing FROM-clause (the foreign key is used in the ORDER BY clause but is not JOINed) In my models, the Address model is the problem. The ZIP_Code model is used as the primary ordering field. Really, I just need the zipcode number, but it obviously references the entire object. I had this exact same problem with my Route model, when I used the ZIP_Code model in the ordering and search_fields. I was able to get around it because the primary key is a concatenation of zipcode-carrier route. I hope I've given you enough information, and I really hope I just made a silly mistake somewhere. :) Thanks for the attention, Corey On Aug 11, 2006, at 11:01 AM, Adrian Holovaty wrote:
|
- Re: Searching in admin doesn't search -- returns everythi... Adrian Holovaty
- Re: Searching in admin doesn't search -- returns eve... Corey Oordt
- Re: Searching in admin doesn't search -- returns... Jeremy Dunck
- Re: Re: Searching in admin doesn't search --... Matthew Flanagan