List:Commits« Previous MessageNext Message »
From:paul Date:January 4 2006 11:59pm
Subject:svn commit - mysqldoc@docsrva: r682 - in trunk: . refman-4.1 refman-5.0 refman-5.1
View as plain text  
Author: paul
Date: 2006-01-05 00:59:18 +0100 (Thu, 05 Jan 2006)
New Revision: 682

Log:
 r5853@frost:  paul | 2006-01-04 17:15:52 -0600
 Revise information about /* */ comment extensions.


Modified:
   trunk/
   trunk/refman-4.1/introduction.xml
   trunk/refman-4.1/language-structure.xml
   trunk/refman-5.0/introduction.xml
   trunk/refman-5.0/language-structure.xml
   trunk/refman-5.1/introduction.xml
   trunk/refman-5.1/language-structure.xml


Property changes on: trunk
___________________________________________________________________
Name: svk:merge
   - b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:5847
bf112a9c-6c03-0410-a055-ad865cd57414:/mysqldoc-local/mysqldoc/trunk:1933
   + b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:5853
bf112a9c-6c03-0410-a055-ad865cd57414:/mysqldoc-local/mysqldoc/trunk:1933

Modified: trunk/refman-4.1/introduction.xml
===================================================================
--- trunk/refman-4.1/introduction.xml	2006-01-04 23:52:00 UTC (rev 681)
+++ trunk/refman-4.1/introduction.xml	2006-01-04 23:59:18 UTC (rev 682)
@@ -1320,21 +1320,32 @@
         find in other SQL DBMSs. Be warned that if you use them, your
         code won't be portable to other SQL servers. In some cases, you
         can write code that includes MySQL extensions, but is still
-        portable, by using comments of the form <literal>/*! ...
-        */</literal>. In this case, MySQL Server parses and execute the
-        code within the comment as it would any other MySQL statement,
-        but other SQL servers will ignore the extensions. For example:
+        portable, by using comments of the following form:
       </para>
 
 <programlisting>
-SELECT /*! STRAIGHT_JOIN */ col_name FROM table1,table2 WHERE ...
+/*! <replaceable>MySQL-specific code</replaceable> */
 </programlisting>
 
       <para>
+        In this case, MySQL Server parses and executes the code within
+        the comment as it would any other SQL statement, but other SQL
+        servers will ignore the extensions. For example, MySQL Server
+        recognizes the <literal>STRAIGHT_JOIN</literal> keyword in the
+        following statement, but other servers will not:
+      </para>
+
+<programlisting>
+SELECT /*! STRAIGHT_JOIN */ col1 FROM table1,table2 WHERE ...
+</programlisting>
+
+      <para>
         If you add a version number after the
         &lsquo;<literal>!</literal>&rsquo; character, the syntax within
-        the comment is executed only if the MySQL version is equal to or
-        newer than the specified version number:
+        the comment is executed only if the MySQL version is greater
+        than or equal to the specified version number. The
+        <literal>TEMPORARY</literal> keyword in the following comment is
+        executed only by servers from MySQL 3.23.02 or higher:
       </para>
 
 <programlisting>
@@ -1342,11 +1353,6 @@
 </programlisting>
 
       <para>
-        This means that if you have version 3.23.02 or newer, MySQL
-        Server uses the <literal>TEMPORARY</literal> keyword.
-      </para>
-
-      <para>
         The following descriptions list MySQL extensions, organized by
         category.
       </para>

Modified: trunk/refman-4.1/language-structure.xml
===================================================================
--- trunk/refman-4.1/language-structure.xml	2006-01-04 23:52:00 UTC (rev 681)
+++ trunk/refman-4.1/language-structure.xml	2006-01-04 23:59:18 UTC (rev 682)
@@ -1864,13 +1864,8 @@
       <secondary>adding</secondary>
     </indexterm>
 
-    <remark role="todo">
-      this is really the place to describe /*!...*/ and /*!nnnnn ... */
-      comment syntax.
-    </remark>
-
     <para>
-      The MySQL server supports three comment styles:
+      MySQL Server supports three comment styles:
     </para>
 
     <itemizedlist>
@@ -1923,6 +1918,41 @@
 </programlisting>
 
     <para>
+      MySQL Server supports some variants of C-style comments. These
+      enable you to write code that includes MySQL extensions, but is
+      still portable, by using comments of the following form:
+    </para>
+
+<programlisting>
+/*! <replaceable>MySQL-specific code</replaceable> */
+</programlisting>
+
+    <para>
+      In this case, MySQL Server parses and executes the code within the
+      comment as it would any other SQL statement, but other SQL servers
+      will ignore the extensions. For example, MySQL Server recognizes
+      the <literal>STRAIGHT_JOIN</literal> keyword in the following
+      statement, but other servers will not:
+    </para>
+
+<programlisting>
+SELECT /*! STRAIGHT_JOIN */ col1 FROM table1,table2 WHERE ...
+</programlisting>
+
+    <para>
+      If you add a version number after the
+      &lsquo;<literal>!</literal>&rsquo; character, the syntax within
+      the comment is executed only if the MySQL version is greater than
+      or equal to the specified version number. The
+      <literal>TEMPORARY</literal> keyword in the following comment is
+      executed only by servers from MySQL 3.23.02 or higher:
+    </para>
+
+<programlisting>
+CREATE /*!32302 TEMPORARY */ TABLE t (a INT);
+</programlisting>
+
+    <para>
       The comment syntax just described applies to how the
       <command>mysqld</command> server parses SQL statements. The
       <command>mysql</command> client program also performs some parsing

Modified: trunk/refman-5.0/introduction.xml
===================================================================
--- trunk/refman-5.0/introduction.xml	2006-01-04 23:52:00 UTC (rev 681)
+++ trunk/refman-5.0/introduction.xml	2006-01-04 23:59:18 UTC (rev 682)
@@ -789,7 +789,7 @@
 
     <para>
       MySQL supports high-availability database clustering using the
-      <literal>NDBCluster</literal> storage engine. See 
+      <literal>NDBCluster</literal> storage engine. See
       <xref linkend="ndbcluster"/>.
     </para>
 
@@ -926,21 +926,32 @@
         find in other SQL DBMSs. Be warned that if you use them, your
         code won't be portable to other SQL servers. In some cases, you
         can write code that includes MySQL extensions, but is still
-        portable, by using comments of the form <literal>/*! ...
-        */</literal>. In this case, MySQL Server parses and execute the
-        code within the comment as it would any other MySQL statement,
-        but other SQL servers will ignore the extensions. For example:
+        portable, by using comments of the following form:
       </para>
 
 <programlisting>
-SELECT /*! STRAIGHT_JOIN */ col_name FROM table1,table2 WHERE ...
+/*! <replaceable>MySQL-specific code</replaceable> */
 </programlisting>
 
       <para>
+        In this case, MySQL Server parses and executes the code within
+        the comment as it would any other SQL statement, but other SQL
+        servers will ignore the extensions. For example, MySQL Server
+        recognizes the <literal>STRAIGHT_JOIN</literal> keyword in the
+        following statement, but other servers will not:
+      </para>
+
+<programlisting>
+SELECT /*! STRAIGHT_JOIN */ col1 FROM table1,table2 WHERE ...
+</programlisting>
+
+      <para>
         If you add a version number after the
         &lsquo;<literal>!</literal>&rsquo; character, the syntax within
-        the comment is executed only if the MySQL version is equal to or
-        newer than the specified version number:
+        the comment is executed only if the MySQL version is greater
+        than or equal to the specified version number. The
+        <literal>TEMPORARY</literal> keyword in the following comment is
+        executed only by servers from MySQL 3.23.02 or higher:
       </para>
 
 <programlisting>
@@ -948,11 +959,6 @@
 </programlisting>
 
       <para>
-        This means that if you have version 3.23.02 or newer, MySQL
-        Server uses the <literal>TEMPORARY</literal> keyword.
-      </para>
-
-      <para>
         The following descriptions list MySQL extensions, organized by
         category.
       </para>

Modified: trunk/refman-5.0/language-structure.xml
===================================================================
--- trunk/refman-5.0/language-structure.xml	2006-01-04 23:52:00 UTC (rev 681)
+++ trunk/refman-5.0/language-structure.xml	2006-01-04 23:59:18 UTC (rev 682)
@@ -1848,13 +1848,8 @@
       <secondary>adding</secondary>
     </indexterm>
 
-    <remark role="todo">
-      this is really the place to describe /*!...*/ and /*!nnnnn ...
-      comment syntax.
-    </remark>
-
     <para>
-      The MySQL server supports three comment styles:
+      MySQL server supports three comment styles:
     </para>
 
     <itemizedlist>
@@ -1906,6 +1901,41 @@
 </programlisting>
 
     <para>
+      MySQL Server supports some variants of C-style comments. These
+      enable you to write code that includes MySQL extensions, but is
+      still portable, by using comments of the following form:
+    </para>
+
+<programlisting>
+/*! <replaceable>MySQL-specific code</replaceable> */
+</programlisting>
+
+    <para>
+      In this case, MySQL Server parses and executes the code within the
+      comment as it would any other SQL statement, but other SQL servers
+      will ignore the extensions. For example, MySQL Server recognizes
+      the <literal>STRAIGHT_JOIN</literal> keyword in the following
+      statement, but other servers will not:
+    </para>
+
+<programlisting>
+SELECT /*! STRAIGHT_JOIN */ col1 FROM table1,table2 WHERE ...
+</programlisting>
+
+    <para>
+      If you add a version number after the
+      &lsquo;<literal>!</literal>&rsquo; character, the syntax within
+      the comment is executed only if the MySQL version is greater than
+      or equal to the specified version number. The
+      <literal>TEMPORARY</literal> keyword in the following comment is
+      executed only by servers from MySQL 3.23.02 or higher:
+    </para>
+
+<programlisting>
+CREATE /*!32302 TEMPORARY */ TABLE t (a INT);
+</programlisting>
+
+    <para>
       The comment syntax just described applies to how the
       <command>mysqld</command> server parses SQL statements. The
       <command>mysql</command> client program also performs some parsing

Modified: trunk/refman-5.1/introduction.xml
===================================================================
--- trunk/refman-5.1/introduction.xml	2006-01-04 23:52:00 UTC (rev 681)
+++ trunk/refman-5.1/introduction.xml	2006-01-04 23:59:18 UTC (rev 682)
@@ -543,14 +543,14 @@
 
     <para>
       MySQL supports high-availability database clustering using the
-      <literal>NDBCluster</literal> storage engine. See 
+      <literal>NDBCluster</literal> storage engine. See
       <xref linkend="ndbcluster"/>.
     </para>
 
     <remark role="todo">
       [js] Add link to following para when one exists.
     </remark>
-    
+
     <para>
       We are implementing XML functionality beginning in MySQL 5.1,
       which supports most of the W3C XPath standard. We plan to increase
@@ -685,21 +685,32 @@
         find in other SQL DBMSs. Be warned that if you use them, your
         code won't be portable to other SQL servers. In some cases, you
         can write code that includes MySQL extensions, but is still
-        portable, by using comments of the form <literal>/*! ...
-        */</literal>. In this case, MySQL Server parses and execute the
-        code within the comment as it would any other MySQL statement,
-        but other SQL servers will ignore the extensions. For example:
+        portable, by using comments of the following form:
       </para>
 
 <programlisting>
-SELECT /*! STRAIGHT_JOIN */ col_name FROM table1,table2 WHERE ...
+/*! <replaceable>MySQL-specific code</replaceable> */
 </programlisting>
 
       <para>
+        In this case, MySQL Server parses and executes the code within
+        the comment as it would any other SQL statement, but other SQL
+        servers will ignore the extensions. For example, MySQL Server
+        recognizes the <literal>STRAIGHT_JOIN</literal> keyword in the
+        following statement, but other servers will not:
+      </para>
+
+<programlisting>
+SELECT /*! STRAIGHT_JOIN */ col1 FROM table1,table2 WHERE ...
+</programlisting>
+
+      <para>
         If you add a version number after the
         &lsquo;<literal>!</literal>&rsquo; character, the syntax within
-        the comment is executed only if the MySQL version is equal to or
-        newer than the specified version number:
+        the comment is executed only if the MySQL version is greater
+        than or equal to the specified version number. The
+        <literal>TEMPORARY</literal> keyword in the following comment is
+        executed only by servers from MySQL 3.23.02 or higher:
       </para>
 
 <programlisting>
@@ -707,11 +718,6 @@
 </programlisting>
 
       <para>
-        This means that if you have version 3.23.02 or newer, MySQL
-        Server uses the <literal>TEMPORARY</literal> keyword.
-      </para>
-
-      <para>
         The following descriptions list MySQL extensions, organized by
         category.
       </para>

Modified: trunk/refman-5.1/language-structure.xml
===================================================================
--- trunk/refman-5.1/language-structure.xml	2006-01-04 23:52:00 UTC (rev 681)
+++ trunk/refman-5.1/language-structure.xml	2006-01-04 23:59:18 UTC (rev 682)
@@ -1848,13 +1848,8 @@
       <secondary>adding</secondary>
     </indexterm>
 
-    <remark role="todo">
-      this is really the place to describe /*!...*/ and /*!nnnnn ...
-      comment syntax.
-    </remark>
-
     <para>
-      The MySQL server supports three comment styles:
+      MySQL server supports three comment styles:
     </para>
 
     <itemizedlist>
@@ -1906,6 +1901,41 @@
 </programlisting>
 
     <para>
+      MySQL Server supports some variants of C-style comments. These
+      enable you to write code that includes MySQL extensions, but is
+      still portable, by using comments of the following form:
+    </para>
+
+<programlisting>
+/*! <replaceable>MySQL-specific code</replaceable> */
+</programlisting>
+
+    <para>
+      In this case, MySQL Server parses and executes the code within the
+      comment as it would any other SQL statement, but other SQL servers
+      will ignore the extensions. For example, MySQL Server recognizes
+      the <literal>STRAIGHT_JOIN</literal> keyword in the following
+      statement, but other servers will not:
+    </para>
+
+<programlisting>
+SELECT /*! STRAIGHT_JOIN */ col1 FROM table1,table2 WHERE ...
+</programlisting>
+
+    <para>
+      If you add a version number after the
+      &lsquo;<literal>!</literal>&rsquo; character, the syntax within
+      the comment is executed only if the MySQL version is greater than
+      or equal to the specified version number. The
+      <literal>TEMPORARY</literal> keyword in the following comment is
+      executed only by servers from MySQL 3.23.02 or higher:
+    </para>
+
+<programlisting>
+CREATE /*!32302 TEMPORARY */ TABLE t (a INT);
+</programlisting>
+
+    <para>
       The comment syntax just described applies to how the
       <command>mysqld</command> server parses SQL statements. The
       <command>mysql</command> client program also performs some parsing

Thread
svn commit - mysqldoc@docsrva: r682 - in trunk: . refman-4.1 refman-5.0 refman-5.1paul5 Jan