Why does section 6.4.3.a.i of that linked standard not apply to his sub select?

In the quote below, CR is Column Reference, CN is Column Name.

3) If CR does not contain a <qualifier>, then CR shall be contained
            within the scope of one or more <table name>s or <correlation
            name>s whose associated tables include a column whose <column
            name> is CN. Let the phrase possible qualifiers denote those
            <table name>s and <correlation name>s.

            a) Case:

              i) If the most local scope contains exactly one possible
                 qualifier, then the qualifier Q equivalent to that unique
                 <table name> or <correlation name> is implicit.



> On 28 Dec 2019, at 9:48 am, Simon Slavin <slav...@bigfraud.org> wrote:
> 
> On 28 Dec 2019, at 5:19pm, Barry Smith <smith.bar...@gmail.com> wrote:
> 
>> Is not identifier resolution (search in the current scope first then step 
>> out) part of the SQL standard?
> 
> The way the SELECT statements are nested in the question is itself 
> non-standard in any version of SQL I can cite in this message.
> 
>> Damn closed standards and their inability to check without paying through 
>> the nose.
> 
> For that reason, we quote the 180,000 word SQL-92 …
> 
> <https://www.contrib.andrew.cmu.edu/~shadow/sql/sql1992.txt>
> 
> … quite a lot, and the nine parts of SQL:2016 never.  (Hmm.  No, there's no 
> SQL:2019 yet.)
> 
>> Even if not, and this is in fact undocumented, I would be amazed if it 
>> changed, purely for the sheer amount of software it would break.
> 
> 
> Oh, me too.  But I wouldn't intentionally write code that depended on it.  
> Nor would I recommend that to anyone else.  Every time a developer says "We 
> do <illogical thing> for backward compatibility." I die a little.
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to