Hi Maximiliano,
Sorry for the delay in responding to this.
On Thursday 22 May 2014 17:06:23 Maximiliano Robaina wrote:
> El jueves, 22 de mayo de 2014 03:24:12 UTC-3, Shai Berger escribió:
> >
> > Quoting it uncoditionally would break the test on Oracle (which, by
> > default, turns all the names to uppercase). There is a feature-flag for
> > it...
>
> How this feature flag should works?
It's called "uppercases_column_names". The way it should work is -- it should
be False for backends that don't change the case of names, and True for Oracle
(currently, it is actually reversed; fixing it is on my to-do, but I haven't
gotten to it yet).
It lowercases the name back in introspection
https://github.com/django/django/blob/1.7b4/django/db/backends/oracle/introspection.py#L62
And yes, this behavior completely breaks things if you try to really use
lowercase in names. I am on record describing the Oracle backend's behavior as
"case-insane", but this cannot be changed without breaking backwards
compatibility.
(FWIW, I believe the SQL standard says that unquoted names should be case-
insensitive, which, in turn, means introspection more-or-less must be broken.
uppercasing unquoted input was standard back in the 1960s -- it was an easy
way to differentiate user input from computer output in a time when the
interface was a one-color, one-font teletype. Regretfully, we now need to deal
with the consequences.)
Shai.