List:Commits« Previous MessageNext Message »
From:john.russell Date:May 31 2011 7:49pm
Subject:svn commit - mysqldoc@oter02: r26385 - in trunk: dynamic-docs/command-optvars refman-5.6
View as plain text  
Author: jdrussel
Date: 2011-05-31 21:49:31 +0200 (Tue, 31 May 2011)
New Revision: 26385

Log:
Added information about new innodb_large_prefix option and its relation to
limits on InnoDB indexes.
Will backport to 5.5, but the file structure of the 'restrictions' section is
different there so will use the diff and do in a separate commit.


Modified:
   trunk/dynamic-docs/command-optvars/mysqld.xml
   trunk/refman-5.6/se-innodb-core.xml


Modified: trunk/dynamic-docs/command-optvars/mysqld.xml
===================================================================
--- trunk/dynamic-docs/command-optvars/mysqld.xml	2011-05-31 19:23:08 UTC (rev 26384)
+++ trunk/dynamic-docs/command-optvars/mysqld.xml	2011-05-31 19:49:31 UTC (rev 26385)
Changed blocks: 1, Lines Added: 29, Lines Deleted: 0; 1177 bytes

@@ -12738,6 +12738,35 @@
 
   </mysqloption>
 
+  <mysqloption section="innodb" id="innodb_large_prefix">
+
+    <xrefto id="sysvar_innodb_large_prefix"/>
+
+    <name>innodb_large_prefix</name>
+
+    <shortdescription>
+      Enables longer keys for column prefix indexes
+    </shortdescription>
+
+    <types>
+      <optype class="cmdline" format="--innodb_large_prefix" setvar="innodb_large_prefix"/>
+      <optype class="mycnf"/>
+      <vartype class="system" scope="global" isdynamic="yes"/>
+    </types>
+
+    <values vartype="boolean" platform="all">
+      <value default="ON"/>
+    </values>
+
+    <versions>
+      <manual version="5.5"/>
+      <manual version="5.6"/>
+      <introduced version="5.5.15"/>
+      <introduced version="5.6.4"/>
+    </versions>
+
+  </mysqloption>
+
   <mysqloption section="innodb" id="innodb_lock_wait_timeout">
 
     <xrefto id="sysvar_innodb_lock_wait_timeout"/>


Modified: trunk/refman-5.6/se-innodb-core.xml
===================================================================
--- trunk/refman-5.6/se-innodb-core.xml	2011-05-31 19:23:08 UTC (rev 26384)
+++ trunk/refman-5.6/se-innodb-core.xml	2011-05-31 19:49:31 UTC (rev 26385)
Changed blocks: 4, Lines Added: 73, Lines Deleted: 14; 5343 bytes

@@ -11013,6 +11013,49 @@
         </listitem>
 
         <listitem>
+          <para id="sysvar_innodb_large_prefix">
+            <indexterm>
+              <primary>innodb_large_prefix system variable</primary>
+            </indexterm>
+
+            <indexterm>
+              <primary>InnoDB parameters, new</primary>
+              <secondary>innodb_large_prefix</secondary>
+            </indexterm>
+
+            <literal role="sysvar">innodb_large_prefix</literal>
+          </para>
+
+          <para condition="dynamic:optvar:item" role="5.6:mysqld:innodb_large_prefix"/>
+
+          <para>
+            Enable this option to allow index key prefixes longer than
+            767 bytes (up to 3072 bytes), for <literal>InnoDB</literal>
+            tables that use the
+            <literal><link linkend="glos_dynamic_row_format">DYNAMIC</link></literal>
+            and
+            <literal><link linkend="glos_compressed_row_format">COMPRESSED</link></literal>
+            row formats. See <xref linkend="innodb-restrictions"/> for
+            the relevant maximums associated with index key prefixes
+            under various settings.
+          </para>
+
+          <para>
+            For tables using the
+            <literal><link linkend="glos_redundant_row_format">REDUNDANT</link></literal>
+            and
+            <literal><link linkend="glos_compact_row_format">COMPACT</link></literal>
+            row formats, this option does not affect the allowed key
+            prefix length. It does introduce a new error possibility.
+            When this setting is enabled, attempting to create an index
+            prefix with a key length greater than 3072 for a
+            <literal>REDUNDANT</literal> or <literal>COMPACT</literal>
+            table causes an error
+            <literal>ER_INDEX_COLUMN_TOO_LONG</literal> (1727).
+          </para>
+        </listitem>
+
+        <listitem>
           <para id="sysvar_innodb_lock_wait_timeout">
             <indexterm>
               <primary>innodb_lock_wait_timeout system variable</primary>

@@ -12491,26 +12534,46 @@
           </para>
         </listitem>
 
-<!-- JDR: any change in this limit due to Barracuda row formats? -->
-
         <listitem>
           <para>
-            The <literal>InnoDB</literal> internal maximum key length is
-            3500 bytes, but MySQL itself restricts this to 3072 bytes.
+            The <literal>InnoDB</literal> internal maximum index key
+            length is 3500 bytes, but MySQL itself restricts this to
+            3072 bytes. For example, you might hit this limit with a
+            <link linkend="glos_composite_index">composite index</link>
+            containing several <literal>VARCHAR</literal> columns.
           </para>
         </listitem>
 
-<!-- JDR: any change in this limit due to Barracuda row formats? -->
-
         <listitem>
           <para>
-            Index key prefixes can be up to 767 bytes. See
-            <xref linkend="create-index"/>.
+            By default, index key prefixes can be up to 767 bytes. See
+            <xref linkend="create-index"/>. For example, you might hit
+            this limit with a <link linkend="glos_column_prefix">column
+            prefix</link> index of more than 255 characters on a
+            <literal>TEXT</literal> or <literal>VARCHAR</literal>
+            column, assuming a UTF-8 character set and the maximum of 3
+            bytes for each character. When the
+            <literal role="sysvar">innodb_large_prefix</literal>
+            configuration option is enabled, the prefix limit for index
+            keys is raised to 3072 bytes, for <literal>InnoDB</literal>
+            tables that use the
+            <literal><link linkend="glos_dynamic_row_format">DYNAMIC</link></literal>
+            and
+            <literal><link linkend="glos_compressed_row_format">COMPRESSED</link></literal>
+            row formats.
           </para>
+
+          <para>
+            When you attempt to specify an index prefix length longer
+            than allowed, the prefix length is silently reduced to the
+            maximum length. This configuration option changes the error
+            handling for some combinations of row format and prefix
+            length longer than the maximum allowed. See
+            <literal role="sysvar">innodb_large_prefix</literal> for
+            details.
+          </para>
         </listitem>
 
-<!-- JDR: any change in this limit due to Barracuda row formats? -->
-
         <listitem>
           <para>
             The maximum row length, except for variable-length columns

@@ -12527,8 +12590,6 @@
             than 4GB.
           </para>
 
-<!-- JDR: any change in this limit due to Barracuda row formats? -->
-
           <para>
             If a row is less than half a page long, all of it is stored
             locally within the page. If it exceeds half a page,

@@ -12538,8 +12599,6 @@
           </para>
         </listitem>
 
-<!-- JDR: any change in this limit due to Barracuda row formats? -->
-
         <listitem>
           <para>
             Although <literal>InnoDB</literal> supports row sizes larger


Thread
svn commit - mysqldoc@oter02: r26385 - in trunk: dynamic-docs/command-optvars refman-5.6john.russell31 May