Author: paul
Date: 2006-04-20 14:49:21 +0200 (Thu, 20 Apr 2006)
New Revision: 1887
Log:
r9597@frost: paul | 2006-04-20 07:24:25 -0500
Additional information about column resolution in SELECT. (Bug#18064)
Modified:
trunk/
trunk/refman-4.1/sql-syntax.xml
trunk/refman-5.0/sql-syntax.xml
trunk/refman-5.1/sql-syntax.xml
Property changes on: trunk
___________________________________________________________________
Name: svk:merge
- 4767c598-dc10-0410-bea0-d01b485662eb:/mysqldoc-local/mysqldoc/trunk:6782
b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:9595
bf112a9c-6c03-0410-a055-ad865cd57414:/mysqldoc-local/mysqldoc/trunk:4545
+ 4767c598-dc10-0410-bea0-d01b485662eb:/mysqldoc-local/mysqldoc/trunk:6782
b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:9597
bf112a9c-6c03-0410-a055-ad865cd57414:/mysqldoc-local/mysqldoc/trunk:4545
Modified: trunk/refman-4.1/sql-syntax.xml
===================================================================
--- trunk/refman-4.1/sql-syntax.xml 2006-04-20 11:40:55 UTC (rev 1886)
+++ trunk/refman-4.1/sql-syntax.xml 2006-04-20 12:49:21 UTC (rev 1887)
@@ -897,13 +897,13 @@
This assumes that the table <literal>t1</literal> has columns
<literal>col1</literal> and <literal>col2</literal>.
</para>
-
+
<para>
This set of statements will also produce a new table
<literal>t2</literal> identical to <literal>t1</literal>, with
the addition of an <literal>AUTO_INCREMENT</literal> column:
</para>
-
+
<programlisting>
CREATE TABLE t2 LIKE t1;
ALTER TABLE T2 ADD id INT AUTO_INCREMENT PRIMARY KEY;
@@ -6589,6 +6589,18 @@
<listitem>
<para>
+ When MySQL resolves an unqualified column or alias reference
+ in an <literal>ORDER BY</literal>, <literal>GROUP
+ BY</literal>, or <literal>HAVING</literal> clause, it first
+ searches for the name in the
+ <replaceable>select_expr</replaceable> values. If the name
+ is not found, it looks in the columns of the tables named in
+ the <literal>FROM</literal> clause.
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
<indexterm type="function">
<primary>LIMIT</primary>
</indexterm>
Modified: trunk/refman-5.0/sql-syntax.xml
===================================================================
--- trunk/refman-5.0/sql-syntax.xml 2006-04-20 11:40:55 UTC (rev 1886)
+++ trunk/refman-5.0/sql-syntax.xml 2006-04-20 12:49:21 UTC (rev 1887)
@@ -910,13 +910,13 @@
This assumes that the table <literal>t1</literal> has columns
<literal>col1</literal> and <literal>col2</literal>.
</para>
-
+
<para>
This set of statements will also produce a new table
<literal>t2</literal> identical to <literal>t1</literal>, with
the addition of an <literal>AUTO_INCREMENT</literal> column:
</para>
-
+
<programlisting>
CREATE TABLE t2 LIKE t1;
ALTER TABLE T2 ADD id INT AUTO_INCREMENT PRIMARY KEY;
@@ -6632,6 +6632,18 @@
<listitem>
<para>
+ When MySQL resolves an unqualified column or alias reference
+ in an <literal>ORDER BY</literal>, <literal>GROUP
+ BY</literal>, or <literal>HAVING</literal> clause, it first
+ searches for the name in the
+ <replaceable>select_expr</replaceable> values. If the name
+ is not found, it looks in the columns of the tables named in
+ the <literal>FROM</literal> clause.
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
<indexterm type="function">
<primary>LIMIT</primary>
</indexterm>
Modified: trunk/refman-5.1/sql-syntax.xml
===================================================================
--- trunk/refman-5.1/sql-syntax.xml 2006-04-20 11:40:55 UTC (rev 1886)
+++ trunk/refman-5.1/sql-syntax.xml 2006-04-20 12:49:21 UTC (rev 1887)
@@ -1189,13 +1189,13 @@
This assumes that the table <literal>t1</literal> has columns
<literal>col1</literal> and <literal>col2</literal>.
</para>
-
+
<para>
This set of statements will also produce a new table
<literal>t2</literal> identical to <literal>t1</literal>, with
the addition of an <literal>AUTO_INCREMENT</literal> column:
</para>
-
+
<programlisting>
CREATE TABLE t2 LIKE t1;
ALTER TABLE T2 ADD id INT AUTO_INCREMENT PRIMARY KEY;
@@ -7848,6 +7848,18 @@
<listitem>
<para>
+ When MySQL resolves an unqualified column or alias reference
+ in an <literal>ORDER BY</literal>, <literal>GROUP
+ BY</literal>, or <literal>HAVING</literal> clause, it first
+ searches for the name in the
+ <replaceable>select_expr</replaceable> values. If the name
+ is not found, it looks in the columns of the tables named in
+ the <literal>FROM</literal> clause.
+ </para>
+ </listitem>
+
+ <listitem>
+ <para>
<indexterm type="function">
<primary>LIMIT</primary>
</indexterm>
| Thread |
|---|
| • svn commit - mysqldoc@docsrva: r1887 - in trunk: . refman-4.1 refman-5.0 refman-5.1 | paul | 20 Apr |