On Wed, 2007-10-03 at 18:45 +0700, Ben Ford wrote:
> Hi there,
> 
> I've just been looking at some of django's internals trying to get my
> head round the backend refactor...
> 
> I seem to have no luck slicing oracle flavoured QuerySets. From
> reading the source it seems that the limit_offset_sql logic is going
> to be moved to a separate module (called query.py in the backend) but
> this file doesn't exist. There's also what appears to be a lot of
> limit and offset looking code in the _get_sql_clause function of the
> OracleQuerySet class. I'm not at all familiar with oracle I'm afraid,
> but am I right in thinking that this stuff should live in the
> limit_offset_sql function of the DatabaseOperations class and just
> needs to be moved? Or is there a deeper issue causing problems?

I haven't totally decided on the final layout of files for the Oracle
backend, but you're right in thinking that this is currently in the
process of being changed. In the queryset-refactor branch, I'm rewriting
a whole bunch of SQL generation, partially driven by the need to handle
more backend-specific variations (pretty much every backend we support
has some special feature or requirement).

The _get_sql_clause() function is already dead on that branch because it
is very tough to customise. Limit/offset construction is done a bit more
logically. Each backend can customise the way it pulls together the
various pieces to form the SQL query, once we know the tables, aliases,
output columns, constraint clauses, limits, offsets, groupings, and so
forth.

Oracle changes on the queryset-refactor branch are probably going to be
about the last thing to land on that branch because it's very time
consuming to test and work with for me. So I'm getting the rest of the
ducks in line and then making the Oracle changes.

Regards,
Malcolm



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to