List:Internals« Previous MessageNext Message »
From:paul Date:October 17 2005 6:58pm
Subject:svn commit - mysqldoc@docsrva: r73 - in trunk: . refman
View as plain text  
Author: paul
Date: 2005-10-17 20:57:57 +0200 (Mon, 17 Oct 2005)
New Revision: 73

Log:
 r2791@frost:  paul | 2005-10-17 13:56:01 -0500
 Add help markup.


Modified:
   trunk/
   trunk/refman/functions.xml


Property changes on: trunk
___________________________________________________________________
Name: svk:merge
   - b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:2790
   + b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:2791

Modified: trunk/refman/functions.xml
===================================================================
--- trunk/refman/functions.xml	2005-10-17 18:57:38 UTC (rev 72)
+++ trunk/refman/functions.xml	2005-10-17 18:57:57 UTC (rev 73)
@@ -26,9 +26,7 @@
     <primary>operators</primary>
   </indexterm>
 
-  <remark>
-    help_category Functions
-  </remark>
+  <remark role="help-category" condition="Functions"/>
 
   <para>
     Expressions can be used at several points in SQL statements, such as
@@ -190,9 +188,7 @@
         <primary>comparison operators</primary>
       </indexterm>
 
-      <remark>
-        help_category Comparison operators@Functions
-      </remark>
+      <remark role="help-category" condition="Comparison operators@Functions"/>
 
       <indexterm>
         <primary>casts</primary>
@@ -337,10 +333,10 @@
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic =
-          </remark>
+          <remark role="help-topic" condition="="/>
 
+          <remark role="help-description-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>= (equal)</primary>
@@ -357,13 +353,9 @@
             Equal:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic =
-          </remark>
+          <remark role="help-example" condition="="/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 = 0;</userinput>
@@ -380,10 +372,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &lt;=&gt;
-          </remark>
+          <remark role="help-topic" condition="&lt;=&gt;"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm>
               <primary><literal>NULL</literal></primary>
@@ -397,6 +389,10 @@
             <literal>&lt;=&gt;</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             <literal>NULL</literal>-safe equal. This operator performs
             an equality comparison like the <literal>=</literal>
@@ -407,13 +403,9 @@
             <literal>NULL</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &lt;=&gt;
-          </remark>
+          <remark role="help-example" condition="&lt;=&gt;"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 &lt;=&gt; 1, NULL &lt;=&gt; NULL, 1 &lt;=&gt; NULL;</userinput>
@@ -428,10 +420,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic != &lt;&gt;
+          <remark role="help-topic" condition="!="/>
+
+          <remark role="help-keywords">
+            &lt;&gt;
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>&lt;&gt; (not equal)</primary>
@@ -449,20 +445,20 @@
               <primary>not equal (!=)</primary>
             </indexterm>
 
-            <literal>&lt;&gt;</literal>, <literal>!=</literal>
+            <literal>&lt;&gt;</literal> <literal>!=</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Not equal:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic !=
-          </remark>
+          <remark role="help-example" condition="!="/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT '.01' &lt;&gt; '0.01';</userinput>
@@ -475,10 +471,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &lt;=
-          </remark>
+          <remark role="help-topic" condition="&lt;="/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>&lt;= (less than or equal)</primary>
@@ -491,17 +487,17 @@
             <literal>&lt;=</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Less than or equal:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &lt;=
-          </remark>
+          <remark role="help-example" condition="&lt;="/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 0.1 &lt;= 2;</userinput>
@@ -510,10 +506,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &lt;
-          </remark>
+          <remark role="help-topic" condition="&lt;"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>&lt; (less than)</primary>
@@ -526,17 +522,17 @@
             <literal>&lt;</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Less than:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &lt;
-          </remark>
+          <remark role="help-example" condition="&lt;"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 2 &lt; 2;</userinput>
@@ -545,10 +541,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &gt;=
-          </remark>
+          <remark role="help-topic" condition="&gt;="/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>&gt;= (greater than or equal)</primary>
@@ -561,17 +557,17 @@
             <literal>&gt;=</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Greater than or equal:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &gt;=
-          </remark>
+          <remark role="help-example" condition="&gt;="/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 2 &gt;= 2;</userinput>
@@ -580,10 +576,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &gt;
-          </remark>
+          <remark role="help-topic" condition="&gt;"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>&gt; (greater than)</primary>
@@ -596,17 +592,17 @@
             <literal>&gt;</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Greater than:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &gt;
-          </remark>
+          <remark role="help-example" condition="&gt;"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 2 &gt; 2;</userinput>
@@ -615,10 +611,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic IS
-          </remark>
+          <remark role="help-topic" condition="IS"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm>
               <primary><literal>TRUE</literal></primary>
@@ -644,11 +640,15 @@
             </indexterm>
 
             <literal>IS
-            <replaceable>boolean_value</replaceable></literal>,
+            <replaceable>boolean_value</replaceable></literal>
             <literal>IS NOT
             <replaceable>boolean_value</replaceable></literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Tests whether a value against a boolean value, where
             <replaceable>boolean_value</replaceable> can be
@@ -656,13 +656,9 @@
             <literal>UNKNOWN</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic IS
-          </remark>
+          <remark role="help-example" condition="IS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 IS TRUE, 0 IS FALSE, NULL IS UNKNOWN;</userinput>
@@ -679,10 +675,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic IS NULL NULL IS
+          <remark role="help-topic" condition="IS NULL"/>
+
+          <remark role="help-keywords">
+            NULL IS
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm>
               <primary><literal>NULL</literal></primary>
@@ -697,20 +697,20 @@
               <primary>IS NOT NULL</primary>
             </indexterm>
 
-            <literal>IS NULL</literal>, <literal>IS NOT NULL</literal>
+            <literal>IS NULL</literal> <literal>IS NOT NULL</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Tests whether a value is or is not <literal>NULL</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic IS NULL
-          </remark>
+          <remark role="help-example" condition="IS NULL"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 IS NULL, 0 IS NULL, NULL IS NULL;</userinput>
@@ -779,10 +779,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic BETWEEN AND BETWEEN AND
+          <remark role="help-topic" condition="BETWEEN AND"/>
+
+          <remark role="help-keywords">
+            BETWEEN AND
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>BETWEEN ... AND</primary>
@@ -793,6 +797,10 @@
             <replaceable>max</replaceable></literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             If <replaceable>expr</replaceable> is greater than or equal
             to <replaceable>min</replaceable> and
@@ -812,13 +820,9 @@
             <replaceable>expr</replaceable> instead.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic BETWEEN AND
-          </remark>
+          <remark role="help-example" condition="BETWEEN AND"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 BETWEEN 2 AND 3;</userinput>
@@ -833,10 +837,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic NOT BETWEEN
+          <remark role="help-topic" condition="NOT"/>
+
+          <remark role="help-keywords">
+            BETWEEN
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>NOT BETWEEN</primary>
@@ -847,6 +855,10 @@
             <replaceable>max</replaceable></literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             This is the same as <literal>NOT
             (<replaceable>expr</replaceable> BETWEEN
@@ -854,16 +866,14 @@
             <replaceable>max</replaceable>)</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic COALESCE
-          </remark>
+          <remark role="help-topic" condition="COALESCE"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm>
               <primary><literal>NULL</literal></primary>
@@ -877,18 +887,18 @@
             <literal>COALESCE(<replaceable>value</replaceable>,...)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the first non-<literal>NULL</literal> value in the
             list.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic COALESCE
-          </remark>
+          <remark role="help-example" condition="COALESCE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT COALESCE(NULL,1);</userinput>
@@ -903,10 +913,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic GREATEST
-          </remark>
+          <remark role="help-topic" condition="GREATEST"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>GREATEST()</primary>
@@ -915,19 +925,19 @@
             <literal>GREATEST(<replaceable>value1</replaceable>,<replaceable>value2</replaceable>,...)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             With two or more arguments, returns the largest
             (maximum-valued) argument. The arguments are compared using
             the same rules as for <literal>LEAST()</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic GREATEST
-          </remark>
+          <remark role="help-example" condition="GREATEST"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT GREATEST(2,0);</userinput>
@@ -953,10 +963,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic IN
-          </remark>
+          <remark role="help-topic" condition="IN"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>IN</primary>
@@ -966,6 +976,10 @@
             (<replaceable>value</replaceable>,...)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns <literal>1</literal> if
             <replaceable>expr</replaceable> is any of the values in the
@@ -981,13 +995,9 @@
             performed in case-sensitive fashion.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic IN
-          </remark>
+          <remark role="help-example" condition="IN"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 2 IN (0,3,5,'wefwf');</userinput>
@@ -1019,10 +1029,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic NOT IN
+          <remark role="help-topic" condition="NOT"/>
+
+          <remark role="help-keywords">
+            IN
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>NOT IN</primary>
@@ -1032,22 +1046,24 @@
             (<replaceable>value</replaceable>,...)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             This is the same as <literal>NOT
             (<replaceable>expr</replaceable> IN
             (<replaceable>value</replaceable>,...))</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ISNULL
-          </remark>
+          <remark role="help-topic" condition="ISNULL"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ISNULL()</primary>
@@ -1056,6 +1072,10 @@
             <literal>ISNULL(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             If <replaceable>expr</replaceable> is
             <literal>NULL</literal>, <literal>ISNULL()</literal> returns
@@ -1063,13 +1083,9 @@
             <literal>0</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ISNULL
-          </remark>
+          <remark role="help-example" condition="ISNULL"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ISNULL(1+1);</userinput>
@@ -1091,10 +1107,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic INTERVAL
-          </remark>
+          <remark role="help-topic" condition="INTERVAL"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>INTERVAL()</primary>
@@ -1103,6 +1119,10 @@
             <literal>INTERVAL(<replaceable>N</replaceable>,<replaceable>N1</replaceable>,<replaceable>N2</replaceable>,<replaceable>N3</replaceable>,...)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns <literal>0</literal> if <replaceable>N</replaceable>
             &lt; <replaceable>N1</replaceable>, <literal>1</literal> if
@@ -1118,13 +1138,9 @@
             fast).
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic INTERVAL
-          </remark>
+          <remark role="help-example" condition="INTERVAL"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT INTERVAL(23, 1, 15, 17, 30, 44, 200);</userinput>
@@ -1137,10 +1153,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic LEAST
-          </remark>
+          <remark role="help-topic" condition="LEAST"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>LEAST()</primary>
@@ -1149,6 +1165,10 @@
             <literal>LEAST(<replaceable>value1</replaceable>,<replaceable>value2</replaceable>,...)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             With two or more arguments, returns the smallest
             (minimum-valued) argument. The arguments are compared using
@@ -1189,13 +1209,9 @@
 
           </itemizedlist>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic LEAST
-          </remark>
+          <remark role="help-example" condition="LEAST"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LEAST(2,0);</userinput>
@@ -1254,9 +1270,7 @@
         <secondary>logical</secondary>
       </indexterm>
 
-      <remark>
-        help_category Logical operators@Functions
-      </remark>
+      <remark role="help-category" condition="Logical operators@Functions"/>
 
       <para>
         In SQL, all logical operators evaluate to TRUE, FALSE, or
@@ -1270,10 +1284,14 @@
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic ! NOT
+          <remark role="help-topic" condition="!"/>
+
+          <remark role="help-keywords">
+            NOT
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>NOT</primary>
@@ -1284,9 +1302,13 @@
               <primary>! (logical NOT)</primary>
             </indexterm>
 
-            <literal>NOT</literal>, <literal>!</literal>
+            <literal>NOT</literal> <literal>!</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Logical NOT. Evaluates to <literal>1</literal> if the
             operand is <literal>0</literal>, to <literal>0</literal> if
@@ -1294,13 +1316,9 @@
             returns <literal>NULL</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic !
-          </remark>
+          <remark role="help-example" condition="!"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT NOT 10;</userinput>
@@ -1323,10 +1341,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &amp;&amp; AND
+          <remark role="help-topic" condition="&amp;&amp;"/>
+
+          <remark role="help-keywords">
+            AND
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>AND</primary>
@@ -1337,9 +1359,13 @@
               <primary>&amp;&amp; (logical AND)</primary>
             </indexterm>
 
-            <literal>AND</literal>, <literal>&amp;&amp;</literal>
+            <literal>AND</literal> <literal>&amp;&amp;</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Logical AND. Evaluates to <literal>1</literal> if all
             operands are non-zero and not <literal>NULL</literal>, to
@@ -1348,13 +1374,9 @@
             returned.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &amp;&amp;
-          </remark>
+          <remark role="help-example" condition="&amp;&amp;"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 &amp;&amp; 1;</userinput>
@@ -1383,10 +1405,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic || OR
+          <remark role="help-topic" condition="||"/>
+
+          <remark role="help-keywords">
+            OR
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>OR</primary>
@@ -1397,9 +1423,13 @@
               <primary>|| (logical OR)</primary>
             </indexterm>
 
-            <literal>OR</literal>, <literal>||</literal>
+            <literal>OR</literal> <literal>||</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Logical OR. When both operands are
             non-<literal>NULL</literal>, the result is
@@ -1412,13 +1442,9 @@
             <literal>NULL</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ||
-          </remark>
+          <remark role="help-example" condition="||"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 || 1;</userinput>
@@ -1435,10 +1461,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic XOR
-          </remark>
+          <remark role="help-topic" condition="XOR"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>XOR</primary>
@@ -1448,6 +1474,10 @@
             <literal>XOR</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Logical XOR. Returns <literal>NULL</literal> if either
             operand is <literal>NULL</literal>. For
@@ -1456,13 +1486,9 @@
             non-zero, otherwise <literal>0</literal> is returned.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic XOR
-          </remark>
+          <remark role="help-example" condition="XOR"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 XOR 1;</userinput>
@@ -1504,17 +1530,19 @@
       <secondary>control flow</secondary>
     </indexterm>
 
-    <remark>
-      help_category Control flow functions@Functions
-    </remark>
+    <remark role="help-category" condition="Control flow functions@Functions"/>
 
     <itemizedlist>
 
       <listitem>
-        <remark>
-          description_for_help_topic CASE WHEN THEN ELSE END
+        <remark role="help-topic" condition="CASE"/>
+
+        <remark role="help-keywords">
+          WHEN THEN ELSE END
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CASE</primary>
@@ -1525,7 +1553,7 @@
           <replaceable>result</replaceable> [WHEN
           [<replaceable>compare-value</replaceable>] THEN
           <replaceable>result</replaceable> ...] [ELSE
-          <replaceable>result</replaceable>] END</literal>,
+          <replaceable>result</replaceable>] END</literal>
           <literal>CASE WHEN [<replaceable>condition</replaceable>] THEN
           <replaceable>result</replaceable> [WHEN
           [<replaceable>condition</replaceable>] THEN
@@ -1533,6 +1561,10 @@
           <replaceable>result</replaceable>] END</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           The first version returns the
           <replaceable>result</replaceable> where
@@ -1544,13 +1576,9 @@
           part.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic CASE
-        </remark>
+        <remark role="help-example" condition="CASE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CASE 1 WHEN 1 THEN 'one'</userinput>
@@ -1586,10 +1614,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic IF
-        </remark>
+        <remark role="help-topic" condition="IF"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>IF()</primary>
@@ -1598,6 +1626,10 @@
           <literal>IF(<replaceable>expr1</replaceable>,<replaceable>expr2</replaceable>,<replaceable>expr3</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           If <replaceable>expr1</replaceable> is TRUE
           (<literal><replaceable>expr1</replaceable> &lt;&gt;
@@ -1609,13 +1641,9 @@
           which it is used.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic IF
-        </remark>
+        <remark role="help-example" condition="IF"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT IF(1&gt;2,2,3);</userinput>
@@ -1698,10 +1726,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic IFNULL
-        </remark>
+        <remark role="help-topic" condition="IFNULL"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm>
             <primary><literal>NULL</literal></primary>
@@ -1715,6 +1743,10 @@
           <literal>IFNULL(<replaceable>expr1</replaceable>,<replaceable>expr2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           If <replaceable>expr1</replaceable> is not
           <literal>NULL</literal>, <literal>IFNULL()</literal> returns
@@ -1724,13 +1756,9 @@
           which it is used.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic IFNULL
-        </remark>
+        <remark role="help-example" condition="IFNULL"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT IFNULL(1,0);</userinput>
@@ -1766,10 +1794,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic NULLIF
-        </remark>
+        <remark role="help-topic" condition="NULLIF"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>NULLIF()</primary>
@@ -1778,6 +1806,10 @@
           <literal>NULLIF(<replaceable>expr1</replaceable>,<replaceable>expr2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns <literal>NULL</literal> if
           <literal><replaceable>expr1</replaceable> =
@@ -1788,13 +1820,9 @@
           <replaceable>expr1</replaceable> END</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic NULLIF
-        </remark>
+        <remark role="help-example" condition="NULLIF"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT NULLIF(1,1);</userinput>
@@ -1832,9 +1860,7 @@
       <secondary>string</secondary>
     </indexterm>
 
-    <remark>
-      help_category String Functions@Functions
-    </remark>
+    <remark role="help-category" condition="String Functions@Functions"/>
 
     <para>
       String-valued functions return <literal>NULL</literal> if the
@@ -1851,10 +1877,10 @@
     <itemizedlist>
 
       <listitem>
-        <remark>
-          description_for_help_topic ASCII
-        </remark>
+        <remark role="help-topic" condition="ASCII"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>ASCII()</primary>
@@ -1863,6 +1889,10 @@
           <literal>ASCII(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the numeric value of the leftmost character of the
           string <replaceable>str</replaceable>. Returns
@@ -1873,13 +1903,9 @@
           values from <literal>0</literal> to <literal>255</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic ASCII
-        </remark>
+        <remark role="help-example" condition="ASCII"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ASCII('2');</userinput>
@@ -1896,10 +1922,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic BIN
-        </remark>
+        <remark role="help-topic" condition="BIN"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>BIN()</primary>
@@ -1908,6 +1934,10 @@
           <literal>BIN(<replaceable>N</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a string representation of the binary value of
           <replaceable>N</replaceable>, where
@@ -1918,13 +1948,9 @@
           <replaceable>N</replaceable> is <literal>NULL</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic BIN
-        </remark>
+        <remark role="help-example" condition="BIN"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT BIN(12);</userinput>
@@ -1933,10 +1959,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic BIT_LENGTH
-        </remark>
+        <remark role="help-topic" condition="BIT_LENGTH"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>BIT_LENGTH()</primary>
@@ -1945,18 +1971,18 @@
           <literal>BIT_LENGTH(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the length of the string
           <replaceable>str</replaceable> in bits.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic BIT_LENGTH
-        </remark>
+        <remark role="help-example" condition="BIT_LENGTH"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT BIT_LENGTH('text');</userinput>
@@ -1969,10 +1995,14 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CHAR function
+        <remark role="help-topic" condition="CHAR"/>
+
+        <remark role="help-keywords">
+          function
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CHAR()</primary>
@@ -1981,6 +2011,10 @@
           <literal>CHAR(<replaceable>N</replaceable>,...)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>CHAR()</literal> interprets the arguments as integers
           and returns a string consisting of the characters given by the
@@ -1988,13 +2022,9 @@
           are skipped.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic CHAR function
-        </remark>
+        <remark role="help-example" condition="CHAR function"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CHAR(77,121,83,81,'76');</userinput>
@@ -2021,10 +2051,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CHAR_LENGTH
-        </remark>
+        <remark role="help-topic" condition="CHAR_LENGTH"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CHAR_LENGTH()</primary>
@@ -2033,6 +2063,10 @@
           <literal>CHAR_LENGTH(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the length of the string
           <replaceable>str</replaceable>, measured in characters. A
@@ -2043,16 +2077,14 @@
           <literal>5</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CHARACTER_LENGTH
-        </remark>
+        <remark role="help-topic" condition="CHARACTER_LENGTH"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CHARACTER_LENGTH()</primary>
@@ -2061,21 +2093,23 @@
           <literal>CHARACTER_LENGTH(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>CHARACTER_LENGTH()</literal> is a synonym for
           <literal>CHAR_LENGTH()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic COMPRESS
-        </remark>
+        <remark role="help-topic" condition="COMPRESS"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>COMPRESS()</primary>
@@ -2084,6 +2118,10 @@
           <literal>COMPRESS(<replaceable>string_to_compress</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Compresses a string. This function requires MySQL to have been
           compiled with a compression library such as
@@ -2092,13 +2130,9 @@
           uncompressed with <literal>UNCOMPRESS()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic COMPRESS
-        </remark>
+        <remark role="help-example" condition="COMPRESS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LENGTH(COMPRESS(REPEAT('a',1000)));</userinput>
@@ -2146,10 +2180,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CONCAT
-        </remark>
+        <remark role="help-topic" condition="CONCAT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CONCAT()</primary>
@@ -2158,6 +2192,10 @@
           <literal>CONCAT(<replaceable>str1</replaceable>,<replaceable>str2</replaceable>,...)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string that results from concatenating the
           arguments. Returns <literal>NULL</literal> if any argument is
@@ -2171,13 +2209,9 @@
           char_col)</literal>
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic CONCAT
-        </remark>
+        <remark role="help-example" condition="CONCAT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CONCAT('My', 'S', 'QL');</userinput>
@@ -2190,10 +2224,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CONCAT_WS
-        </remark>
+        <remark role="help-topic" condition="CONCAT_WS"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CONCAT_WS()</primary>
@@ -2202,6 +2236,10 @@
           <literal>CONCAT_WS(<replaceable>separator</replaceable>,<replaceable>str1</replaceable>,<replaceable>str2</replaceable>,...)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>CONCAT_WS()</literal> stands for CONCAT With
           Separator and is a special form of
@@ -2214,13 +2252,9 @@
           <literal>NULL</literal> values after the separator argument.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic CONCAT_WS
-        </remark>
+        <remark role="help-example" condition="CONCAT_WS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CONCAT_WS(',','First name','Second name','Last Name');</userinput>
@@ -2236,10 +2270,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CONV
-        </remark>
+        <remark role="help-topic" condition="CONV"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CONV()</primary>
@@ -2248,6 +2282,10 @@
           <literal>CONV(<replaceable>N</replaceable>,<replaceable>from_base</replaceable>,<replaceable>to_base</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Converts numbers between different number bases. Returns a
           string representation of the number
@@ -2266,13 +2304,9 @@
           64-bit precision.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic CONV
-        </remark>
+        <remark role="help-example" condition="CONV"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CONV('a',16,2);</userinput>
@@ -2287,10 +2321,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic ELT
-        </remark>
+        <remark role="help-topic" condition="ELT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>ELT()</primary>
@@ -2299,6 +2333,10 @@
           <literal>ELT(<replaceable>N</replaceable>,<replaceable>str1</replaceable>,<replaceable>str2</replaceable>,<replaceable>str3</replaceable>,...)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns <replaceable>str1</replaceable> if
           <replaceable>N</replaceable> = <literal>1</literal>,
@@ -2311,13 +2349,9 @@
           <literal>FIELD()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic ELT
-        </remark>
+        <remark role="help-example" condition="ELT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ELT(1, 'ej', 'Heja', 'hej', 'foo');</userinput>
@@ -2328,10 +2362,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic EXPORT_SET
-        </remark>
+        <remark role="help-topic" condition="EXPORT_SET"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>EXPORT_SET()</primary>
@@ -2340,6 +2374,10 @@
           <literal>EXPORT_SET(<replaceable>bits</replaceable>,<replaceable>on</replaceable>,<replaceable>off</replaceable>[,<replaceable>separator</replaceable>[,<replaceable>number_of_bits</replaceable>]])</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a string in which for every bit set in the value
           <replaceable>bits</replaceable>, you get an
@@ -2354,13 +2392,9 @@
           (default 64).
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic EXPORT_SET
-        </remark>
+        <remark role="help-example" condition="EXPORT_SET"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT EXPORT_SET(5,'Y','N',',',4);</userinput>
@@ -2371,10 +2405,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic FIELD
-        </remark>
+        <remark role="help-topic" condition="FIELD"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>FIELD()</primary>
@@ -2383,6 +2417,10 @@
           <literal>FIELD(<replaceable>str</replaceable>,<replaceable>str1</replaceable>,<replaceable>str2</replaceable>,<replaceable>str3</replaceable>,...)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the index of <replaceable>str</replaceable> in the
           <replaceable>str1</replaceable>,
@@ -2407,13 +2445,9 @@
           <literal>ELT()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic FIELD
-        </remark>
+        <remark role="help-example" condition="FIELD"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT FIELD('ej', 'Hej', 'ej', 'Heja', 'hej', 'foo');</userinput>
@@ -2424,10 +2458,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic FIND_IN_SET
-        </remark>
+        <remark role="help-topic" condition="FIND_IN_SET"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>FIND_IN_SET()</primary>
@@ -2436,6 +2470,10 @@
           <literal>FIND_IN_SET(<replaceable>str</replaceable>,<replaceable>strlist</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a value <literal>1</literal> to
           <replaceable>N</replaceable> if the string
@@ -2457,13 +2495,9 @@
           (&lsquo;<literal>,</literal>&rsquo;) character.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic FIND_IN_SET
-        </remark>
+        <remark role="help-example" condition="FIND_IN_SET"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT FIND_IN_SET('b','a,b,c,d');</userinput>
@@ -2486,10 +2520,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic HEX
-        </remark>
+        <remark role="help-topic" condition="HEX"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>HEX()</primary>
@@ -2498,6 +2532,10 @@
           <literal>HEX(<replaceable>N_or_S</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           If <replaceable>N_OR_S</replaceable> is a number, returns a
           string representation of the hexadecimal value of
@@ -2515,13 +2553,9 @@
           hexadecimal digits.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic HEX
-        </remark>
+        <remark role="help-example" condition="HEX"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT HEX(255);</userinput>
@@ -2534,10 +2568,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic INSERT
-        </remark>
+        <remark role="help-topic" condition="INSERT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>INSERT()</primary>
@@ -2546,6 +2580,10 @@
           <literal>INSERT(<replaceable>str</replaceable>,<replaceable>pos</replaceable>,<replaceable>len</replaceable>,<replaceable>newstr</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable>, with the
           substring beginning at position <replaceable>pos</replaceable>
@@ -2559,13 +2597,9 @@
           argument is null.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic INSERT
-        </remark>
+        <remark role="help-example" condition="INSERT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT INSERT('Quadratic', 3, 4, 'What');</userinput>
@@ -2582,10 +2616,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic INSTR
-        </remark>
+        <remark role="help-topic" condition="INSTR"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>INSTR()</primary>
@@ -2594,6 +2628,10 @@
           <literal>INSTR(<replaceable>str</replaceable>,<replaceable>substr</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the position of the first occurrence of substring
           <replaceable>substr</replaceable> in string
@@ -2602,13 +2640,9 @@
           the arguments are swapped.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic INSTR
-        </remark>
+        <remark role="help-example" condition="INSTR"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT INSTR('foobarbar', 'bar');</userinput>
@@ -2625,10 +2659,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LCASE
-        </remark>
+        <remark role="help-topic" condition="LCASE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LCASE()</primary>
@@ -2637,21 +2671,23 @@
           <literal>LCASE(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>LCASE()</literal> is a synonym for
           <literal>LOWER()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LEFT
-        </remark>
+        <remark role="help-topic" condition="LEFT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LEFT()</primary>
@@ -2660,18 +2696,18 @@
           <literal>LEFT(<replaceable>str</replaceable>,<replaceable>len</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the leftmost <replaceable>len</replaceable> characters
           from the string <replaceable>str</replaceable>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic LEFT
-        </remark>
+        <remark role="help-example" condition="LEFT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LEFT('foobarbar', 5);</userinput>
@@ -2680,10 +2716,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LENGTH
-        </remark>
+        <remark role="help-topic" condition="LENGTH"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LENGTH()</primary>
@@ -2692,6 +2728,10 @@
           <literal>LENGTH(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the length of the string
           <replaceable>str</replaceable>, measured in bytes. A
@@ -2702,13 +2742,9 @@
           <literal>5</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic LENGTH
-        </remark>
+        <remark role="help-example" condition="LENGTH"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LENGTH('text');</userinput>
@@ -2717,10 +2753,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LOAD_FILE
-        </remark>
+        <remark role="help-topic" condition="LOAD_FILE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>FILE</primary>
@@ -2733,6 +2769,10 @@
           <literal>LOAD_FILE(<replaceable>file_name</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Reads the file and returns the file contents as a string. The
           file must be located on the server, you must specify the full
@@ -2748,13 +2788,9 @@
           <literal>NULL</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic LOAD_FILE
-        </remark>
+        <remark role="help-example" condition="LOAD_FILE"/>
 
 <programlisting>
 mysql&gt; <userinput>UPDATE <replaceable>tbl_name</replaceable></userinput>
@@ -2773,10 +2809,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LOCATE
-        </remark>
+        <remark role="help-topic" condition="LOCATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LOCATE()</primary>
@@ -2787,6 +2823,10 @@
           <literal>LOCATE(<replaceable>substr</replaceable>,<replaceable>str</replaceable>,<replaceable>pos</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           The first syntax returns the position of the first occurrence
           of substring <replaceable>substr</replaceable> in string
@@ -2799,13 +2839,9 @@
           <replaceable>str</replaceable>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic POSITION
-        </remark>
+        <remark role="help-example" condition="POSITION"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LOCATE('bar', 'foobarbar');</userinput>
@@ -2824,10 +2860,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LOWER
-        </remark>
+        <remark role="help-topic" condition="LOWER"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LOWER()</primary>
@@ -2836,19 +2872,19 @@
           <literal>LOWER(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable> with all
           characters changed to lowercase according to the current
           character set mapping (the default is cp1252 Latin1).
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic LOWER
-        </remark>
+        <remark role="help-example" condition="LOWER"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LOWER('QUADRATICALLY');</userinput>
@@ -2861,10 +2897,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LPAD
-        </remark>
+        <remark role="help-topic" condition="LPAD"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LPAD()</primary>
@@ -2882,14 +2918,14 @@
           to <replaceable>len</replaceable> characters.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-syntax-end"/>
 
-        <remark>
-          example_for_help_topic LPAD
-        </remark>
+        <remark role="help-description-begin"/>
 
+        <remark role="help-description-end"/>
+
+        <remark role="help-example" condition="LPAD"/>
+
 <programlisting>
 mysql&gt; <userinput>SELECT LPAD('hi',4,'??');</userinput>
         -&gt; '??hi'
@@ -2899,10 +2935,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LTRIM
-        </remark>
+        <remark role="help-topic" condition="LTRIM"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LTRIM()</primary>
@@ -2911,18 +2947,18 @@
           <literal>LTRIM(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable> with leading
           space characters removed.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic LTRIM
-        </remark>
+        <remark role="help-example" condition="LTRIM"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LTRIM('  barbar');</userinput>
@@ -2935,10 +2971,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic MAKE_SET
-        </remark>
+        <remark role="help-topic" condition="MAKE_SET"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MAKE_SET()</primary>
@@ -2947,6 +2983,10 @@
           <literal>MAKE_SET(<replaceable>bits</replaceable>,<replaceable>str1</replaceable>,<replaceable>str2</replaceable>,...)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a set value (a string containing substrings separated
           by &lsquo;<literal>,</literal>&rsquo; characters) consisting
@@ -2960,13 +3000,9 @@
           not appended to the result.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic MAKE_SET
-        </remark>
+        <remark role="help-example" condition="MAKE_SET"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MAKE_SET(1,'a','b','c');</userinput>
@@ -2981,10 +3017,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic MID
-        </remark>
+        <remark role="help-topic" condition="MID"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MID()</primary>
@@ -2993,22 +3029,24 @@
           <literal>MID(<replaceable>str</replaceable>,<replaceable>pos</replaceable>,<replaceable>len</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>MID(<replaceable>str</replaceable>,<replaceable>pos</replaceable>,<replaceable>len</replaceable>)</literal>
           is a synonym for
           <literal>SUBSTRING(<replaceable>str</replaceable>,<replaceable>pos</replaceable>,<replaceable>len</replaceable>)</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic OCT
-        </remark>
+        <remark role="help-topic" condition="OCT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>OCT()</primary>
@@ -3017,6 +3055,10 @@
           <literal>OCT(<replaceable>N</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a string representation of the octal value of
           <replaceable>N</replaceable>, where
@@ -3027,13 +3069,9 @@
           <literal>NULL</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic OCT
-        </remark>
+        <remark role="help-example" condition="OCT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT OCT(12);</userinput>
@@ -3042,10 +3080,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic OCTETLENGTH
-        </remark>
+        <remark role="help-topic" condition="OCTETLENGTH"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>OCTET_LENGTH()</primary>
@@ -3054,21 +3092,23 @@
           <literal>OCTET_LENGTH(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>OCTET_LENGTH()</literal> is a synonym for
           <literal>LENGTH()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic ORD
-        </remark>
+        <remark role="help-topic" condition="ORD"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>ORD()</primary>
@@ -3077,6 +3117,10 @@
           <literal>ORD(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           If the leftmost character of the string
           <replaceable>str</replaceable> is a multi-byte character,
@@ -3096,13 +3140,9 @@
           <literal>ASCII()</literal> function.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic ORD
-        </remark>
+        <remark role="help-example" condition="ORD"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ORD('2');</userinput>
@@ -3111,10 +3151,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic POSITION
-        </remark>
+        <remark role="help-topic" condition="POSITION"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>POSITION()</primary>
@@ -3124,22 +3164,24 @@
           <replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>POSITION(<replaceable>substr</replaceable> IN
           <replaceable>str</replaceable>)</literal> is a synonym for
           <literal>LOCATE(<replaceable>substr</replaceable>,<replaceable>str</replaceable>)</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic QUOTE
-        </remark>
+        <remark role="help-topic" condition="QUOTE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>QUOTE()</primary>
@@ -3148,6 +3190,10 @@
           <literal>QUOTE(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Quotes a string to produce a result that can be used as a
           properly escaped data value in an SQL statement. The string is
@@ -3160,13 +3206,9 @@
           <literal>QUOTE()</literal> function was added in MySQL 4.0.3.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic QUOTE
-        </remark>
+        <remark role="help-example" condition="QUOTE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT QUOTE('Don\'t!');</userinput>
@@ -3177,10 +3219,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic REPEAT
-        </remark>
+        <remark role="help-topic" condition="REPEAT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>REPEAT()</primary>
@@ -3189,6 +3231,10 @@
           <literal>REPEAT(<replaceable>str</replaceable>,<replaceable>count</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a string consisting of the string
           <replaceable>str</replaceable> repeated
@@ -3199,13 +3245,9 @@
           <replaceable>count</replaceable> are <literal>NULL</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic REPEAT
-        </remark>
+        <remark role="help-example" condition="REPEAT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT REPEAT('MySQL', 3);</userinput>
@@ -3214,10 +3256,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic REPLACE
-        </remark>
+        <remark role="help-topic" condition="REPLACE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>REPLACE()</primary>
@@ -3226,19 +3268,19 @@
           <literal>REPLACE(<replaceable>str</replaceable>,<replaceable>from_str</replaceable>,<replaceable>to_str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable> with all
           occurrences of the string <replaceable>from_str</replaceable>
           replaced by the string <replaceable>to_str</replaceable>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic REPLACE
-        </remark>
+        <remark role="help-example" condition="REPLACE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT REPLACE('www.mysql.com', 'w', 'Ww');</userinput>
@@ -3251,10 +3293,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic REVERSE
-        </remark>
+        <remark role="help-topic" condition="REVERSE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>REVERSE()</primary>
@@ -3263,18 +3305,18 @@
           <literal>REVERSE(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable> with the
           order of the characters reversed.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic REVERSE
-        </remark>
+        <remark role="help-example" condition="REVERSE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT REVERSE('abc');</userinput>
@@ -3287,10 +3329,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic RIGHT
-        </remark>
+        <remark role="help-topic" condition="RIGHT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>RIGHT()</primary>
@@ -3299,18 +3341,18 @@
           <literal>RIGHT(<replaceable>str</replaceable>,<replaceable>len</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the rightmost <replaceable>len</replaceable>
           characters from the string <replaceable>str</replaceable>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic RIGHT
-        </remark>
+        <remark role="help-example" condition="RIGHT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT RIGHT('foobarbar', 4);</userinput>
@@ -3323,10 +3365,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic RPAD
-        </remark>
+        <remark role="help-topic" condition="RPAD"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>RPAD()</primary>
@@ -3335,6 +3377,10 @@
           <literal>RPAD(<replaceable>str</replaceable>,<replaceable>len</replaceable>,<replaceable>padstr</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable>,
           right-padded with the string <replaceable>padstr</replaceable>
@@ -3344,13 +3390,9 @@
           to <replaceable>len</replaceable> characters.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic RPAD
-        </remark>
+        <remark role="help-example" condition="RPAD"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT RPAD('hi',5,'?');</userinput>
@@ -3365,10 +3407,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic RTRIM
-        </remark>
+        <remark role="help-topic" condition="RTRIM"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>RTRIM()</primary>
@@ -3377,18 +3419,18 @@
           <literal>RTRIM(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable> with
           trailing space characters removed.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic RTRIM
-        </remark>
+        <remark role="help-example" condition="RTRIM"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT RTRIM('barbar   ');</userinput>
@@ -3401,10 +3443,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SOUNDEX
-        </remark>
+        <remark role="help-topic" condition="SOUNDEX"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SOUNDEX()</primary>
@@ -3413,6 +3455,10 @@
           <literal>SOUNDEX(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a soundex string from <replaceable>str</replaceable>.
           Two strings that sound almost the same should have identical
@@ -3425,13 +3471,9 @@
           outside the A-Z range are treated as vowels.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic SOUNDEX
-        </remark>
+        <remark role="help-example" condition="SOUNDEX"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SOUNDEX('Hello');</userinput>
@@ -3451,10 +3493,14 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SOUNDS LIKE SOUNDS LIKE
+        <remark role="help-topic" condition="SOUNDS LIKE"/>
+
+        <remark role="help-keywords">
+          SOUNDS LIKE
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SOUNDS LIKE</primary>
@@ -3464,6 +3510,10 @@
           <replaceable>expr2</replaceable></literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           This is the same as
           <literal>SOUNDEX(<replaceable>expr1</replaceable>) =
@@ -3471,16 +3521,14 @@
           available only in MySQL 4.1 or later.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SPACE
-        </remark>
+        <remark role="help-topic" condition="SPACE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SPACE()</primary>
@@ -3489,18 +3537,18 @@
           <literal>SPACE(<replaceable>N</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a string consisting of <replaceable>N</replaceable>
           space characters.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic SPACE
-        </remark>
+        <remark role="help-example" condition="SPACE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SPACE(6);</userinput>
@@ -3509,10 +3557,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SUBSTRING
-        </remark>
+        <remark role="help-topic" condition="SUBSTRING"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SUBSTRING()</primary>
@@ -3524,13 +3572,17 @@
 
           <literal>SUBSTRING(<replaceable>str</replaceable>,<replaceable>pos</replaceable>)</literal>
           , <literal>SUBSTRING(<replaceable>str</replaceable> FROM
-          <replaceable>pos</replaceable>)</literal>,
+          <replaceable>pos</replaceable>)</literal>
           <literal>SUBSTRING(<replaceable>str</replaceable>,<replaceable>pos</replaceable>,<replaceable>len</replaceable>)</literal>
           , <literal>SUBSTRING(<replaceable>str</replaceable> FROM
           <replaceable>pos</replaceable> FOR
           <replaceable>len</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           The forms without a <replaceable>len</replaceable> argument
           return a substring from string <replaceable>str</replaceable>
@@ -3548,13 +3600,9 @@
           in any of the forms of this function.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic SUBSTRING
-        </remark>
+        <remark role="help-example" condition="SUBSTRING"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SUBSTRING('Quadratically',5);</userinput>
@@ -3588,10 +3636,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SUBSTRING_INDEX
-        </remark>
+        <remark role="help-topic" condition="SUBSTRING_INDEX"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SUBSTRING_INDEX()</primary>
@@ -3600,6 +3648,10 @@
           <literal>SUBSTRING_INDEX(<replaceable>str</replaceable>,<replaceable>delim</replaceable>,<replaceable>count</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the substring from string
           <replaceable>str</replaceable> before
@@ -3612,13 +3664,9 @@
           the right) is returned.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic SUBSTRING_INDEX
-        </remark>
+        <remark role="help-example" condition="SUBSTRING_INDEX"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SUBSTRING_INDEX('www.mysql.com', '.', 2);</userinput>
@@ -3633,10 +3681,14 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TRIM BOTH LEADING TRAILING FROM
+        <remark role="help-topic" condition="TRIM"/>
+
+        <remark role="help-keywords">
+          BOTH LEADING TRAILING FROM
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TRIM()</primary>
@@ -3644,11 +3696,15 @@
 
           <literal>TRIM([{BOTH | LEADING | TRAILING}
           [<replaceable>remstr</replaceable>] FROM]
-          <replaceable>str</replaceable>)</literal>,
+          <replaceable>str</replaceable>)</literal>
           <literal>TRIM(<replaceable>remstr</replaceable> FROM]
           <replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable> with all
           <replaceable>remstr</replaceable> prefixes and/or suffixes
@@ -3659,13 +3715,9 @@
           specified, spaces are removed.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic TRIM
-        </remark>
+        <remark role="help-example" condition="TRIM"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TRIM('  bar   ');</userinput>
@@ -3684,10 +3736,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UCASE
-        </remark>
+        <remark role="help-topic" condition="UCASE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UCASE()</primary>
@@ -3696,21 +3748,23 @@
           <literal>UCASE(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>UCASE()</literal> is a synonym for
           <literal>UPPER()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UNCOMPRESS
-        </remark>
+        <remark role="help-topic" condition="UNCOMPRESS"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UNCOMPRESS()</primary>
@@ -3719,6 +3773,10 @@
           <literal>UNCOMPRESS(<replaceable>string_to_uncompress</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Uncompresses a string compressed by the
           <literal>COMPRESS()</literal> function. If the argument is not
@@ -3728,13 +3786,9 @@
           Otherwise, the return value is always <literal>NULL</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic UNCOMPRESS
-        </remark>
+        <remark role="help-example" condition="UNCOMPRESS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UNCOMPRESS(COMPRESS('any string'));</userinput>
@@ -3749,10 +3803,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UNCOMPRESSED_LENGTH
-        </remark>
+        <remark role="help-topic" condition="UNCOMPRESSED_LENGTH"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UNCOMPRESSED_LENGTH()</primary>
@@ -3761,17 +3815,17 @@
           <literal>UNCOMPRESSED_LENGTH(<replaceable>compressed_string</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the length of a compressed string before compression.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic UNCOMPRESSED_LENGTH
-        </remark>
+        <remark role="help-example" condition="UNCOMPRESSED_LENGTH"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UNCOMPRESSED_LENGTH(COMPRESS(REPEAT('a',30)));</userinput>
@@ -3785,10 +3839,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UNHEX
-        </remark>
+        <remark role="help-topic" condition="UNHEX"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UNHEX()</primary>
@@ -3797,6 +3851,10 @@
           <literal>UNHEX(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Does the opposite of
           <literal>HEX(<replaceable>str</replaceable>)</literal>. That
@@ -3806,13 +3864,9 @@
           returned as a binary string.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic UNHEX
-        </remark>
+        <remark role="help-example" condition="UNHEX"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UNHEX('4D7953514C');</userinput>
@@ -3831,10 +3885,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UPPER
-        </remark>
+        <remark role="help-topic" condition="UPPER"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UPPER()</primary>
@@ -3843,19 +3897,19 @@
           <literal>UPPER(<replaceable>str</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the string <replaceable>str</replaceable> with all
           characters changed to uppercase according to the current
           character set mapping (the default is cp1252 Latin1).
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic UPPER
-        </remark>
+        <remark role="help-example" condition="UPPER"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UPPER('Hej');</userinput>
@@ -3882,6 +3936,8 @@
         <secondary>string comparison</secondary>
       </indexterm>
 
+      <remark role="help-category" condition="String Functions@Functions"/>
+
       <para>
         MySQL automatically converts numbers to strings as necessary,
         and vice versa.
@@ -3938,10 +3994,14 @@
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic LIKE ESCAPE
+          <remark role="help-topic" condition="LIKE"/>
+
+          <remark role="help-keywords">
+            ESCAPE
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>LIKE</primary>
@@ -3952,6 +4012,10 @@
             '<replaceable>escape-char</replaceable>']</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Pattern matching using SQL simple regular expression
             comparison. Returns <literal>1</literal> (TRUE) or
@@ -3966,6 +4030,8 @@
             can be specified as a string expression or table column.
           </para>
 
+          <remark role="help-description-end"/>
+
           <para>
             With <literal>LIKE</literal> you can use the following two
             wildcard characters in the pattern:
@@ -3992,14 +4058,8 @@
             </tgroup>
           </informaltable>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-example" condition="LIKE"/>
 
-          <remark>
-            example_for_help_topic LIKE
-          </remark>
-
 <programlisting>
 mysql&gt; <userinput>SELECT 'David!' LIKE 'David_';</userinput>
         -&gt; 1
@@ -4093,10 +4153,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic NOT LIKE
-          </remark>
+          <remark role="help-topic" condition="NOT LIKE"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>NOT LIKE</primary>
@@ -4107,6 +4167,10 @@
             '<replaceable>escape-char</replaceable>']</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             This is the same as <literal>NOT
             (<replaceable>expr</replaceable> LIKE
@@ -4114,43 +4178,47 @@
             '<replaceable>escape-char</replaceable>'])</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic NOT REGEXP
-          </remark>
+          <remark role="help-topic" condition="NOT REGEXP"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>NOT REGEXP</primary>
             </indexterm>
 
             <literal><replaceable>expr</replaceable> NOT REGEXP
-            <replaceable>pat</replaceable></literal>,
+            <replaceable>pat</replaceable></literal>
             <literal><replaceable>expr</replaceable> NOT RLIKE
             <replaceable>pat</replaceable></literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             This is the same as <literal>NOT
             (<replaceable>expr</replaceable> REGEXP
             <replaceable>pat</replaceable>)</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic RLIKE REGEXP
+          <remark role="help-topic" condition="RLIKE"/>
+
+          <remark role="help-keywords">
+            REGEXP
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm>
               <primary>mSQL compatibility</primary>
@@ -4170,11 +4238,15 @@
             </indexterm>
 
             <literal><replaceable>expr</replaceable> REGEXP
-            <replaceable>pat</replaceable></literal>,
+            <replaceable>pat</replaceable></literal>
             <literal><replaceable>expr</replaceable> RLIKE
             <replaceable>pat</replaceable></literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Performs a pattern match of a string expression
             <replaceable>expr</replaceable> against a pattern
@@ -4211,13 +4283,9 @@
             sensitive for normal (not binary) strings.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic RLIKE
-          </remark>
+          <remark role="help-example" condition="RLIKE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 'Monty!' REGEXP 'm%y%%';</userinput>
@@ -4241,10 +4309,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic STRCMP
-          </remark>
+          <remark role="help-topic" condition="STRCMP"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>STRCMP()</primary>
@@ -4253,6 +4321,10 @@
             <literal>STRCMP(<replaceable>expr1</replaceable>,<replaceable>expr2</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             <literal>STRCMP()</literal> returns <literal>0</literal> if
             the strings are the same, <literal>-1</literal> if the first
@@ -4260,13 +4332,9 @@
             sort order, and <literal>1</literal> otherwise.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic STRCMP
-          </remark>
+          <remark role="help-example" condition="STRCMP"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT STRCMP('text', 'text2');</userinput>
@@ -4297,10 +4365,6 @@
 
     <title id="title-numeric-functions">&title-numeric-functions;</title>
 
-    <remark>
-      help_category Numeric Functions@Functions
-    </remark>
-
     <section id="arithmetic-functions">
 
       <title id="title-arithmetic-functions">&title-arithmetic-functions;</title>
@@ -4310,6 +4374,8 @@
         <secondary>cast</secondary>
       </indexterm>
 
+      <remark role="help-category" condition="Numeric Functions@Functions"/>
+
       <para>
         The usual arithmetic operators are available. Note that in the
         case of <literal>-</literal>, <literal>+</literal>, and
@@ -4332,10 +4398,10 @@
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic +
-          </remark>
+          <remark role="help-topic" condition="+"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>+ (addition)</primary>
@@ -4348,17 +4414,17 @@
             <literal>+</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Addition:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic +
-          </remark>
+          <remark role="help-example" condition="+"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 3+5;</userinput>
@@ -4367,10 +4433,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic - binary
-          </remark>
+          <remark role="help-topic" condition="- binary"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>- (subtraction)</primary>
@@ -4383,17 +4449,17 @@
             <literal>-</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Subtraction:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic - binary
-          </remark>
+          <remark role="help-example" condition="- binary"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 3-5;</userinput>
@@ -4402,10 +4468,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic - unary
-          </remark>
+          <remark role="help-topic" condition="- unary"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>- (unary minus)</primary>
@@ -4423,17 +4489,17 @@
             <literal>-</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Unary minus. Changes the sign of the argument.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic - unary
-          </remark>
+          <remark role="help-example" condition="- unary"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT - 2;</userinput>
@@ -4450,10 +4516,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic *
-          </remark>
+          <remark role="help-topic" condition="*"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>* (multiplication)</primary>
@@ -4466,17 +4532,17 @@
             <literal>*</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Multiplication:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic *
-          </remark>
+          <remark role="help-example" condition="*"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 3*5;</userinput>
@@ -4495,10 +4561,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic /
-          </remark>
+          <remark role="help-topic" condition="/"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>/ (division)</primary>
@@ -4511,17 +4577,17 @@
             <literal>/</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Division:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic /
-          </remark>
+          <remark role="help-example" condition="/"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 3/5;</userinput>
@@ -4545,10 +4611,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic DIV FLOOR BIGINT
+          <remark role="help-topic" condition="DIV"/>
+
+          <remark role="help-keywords">
+            FLOOR BIGINT
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>DIV</primary>
@@ -4557,18 +4627,18 @@
             <literal>DIV</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Integer division. Similar to <literal>FLOOR()</literal> but
             safe with <literal>BIGINT</literal> values.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic DIV
-          </remark>
+          <remark role="help-example" condition="DIV"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 5 DIV 2;</userinput>
@@ -4588,6 +4658,8 @@
 
       <title id="title-mathematical-functions">&title-mathematical-functions;</title>
 
+      <remark role="help-category" condition="Numeric Functions@Functions"/>
+
       <para>
         All mathematical functions return <literal>NULL</literal> in
         case of an error.
@@ -4605,10 +4677,10 @@
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic ABS
-          </remark>
+          <remark role="help-topic" condition="ABS"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ABS()</primary>
@@ -4617,17 +4689,17 @@
             <literal>ABS(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the absolute value of <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ABS
-          </remark>
+          <remark role="help-example" condition="ABS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ABS(2);</userinput>
@@ -4643,10 +4715,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ACOS
-          </remark>
+          <remark role="help-topic" condition="ACOS"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ACOS()</primary>
@@ -4655,6 +4727,10 @@
             <literal>ACOS(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the arc cosine of <replaceable>X</replaceable>, that
             is, the value whose cosine is <replaceable>X</replaceable>.
@@ -4663,13 +4739,9 @@
             <literal>-1</literal> to <literal>1</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ACOS
-          </remark>
+          <remark role="help-example" condition="ACOS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ACOS(1);</userinput>
@@ -4682,10 +4754,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ASIN
-          </remark>
+          <remark role="help-topic" condition="ASIN"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ASIN()</primary>
@@ -4694,6 +4766,10 @@
             <literal>ASIN(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the arc sine of <replaceable>X</replaceable>, that
             is, the value whose sine is <replaceable>X</replaceable>.
@@ -4702,13 +4778,9 @@
             <literal>-1</literal> to <literal>1</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ASIN
-          </remark>
+          <remark role="help-example" condition="ASIN"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ASIN(0.2);</userinput>
@@ -4719,10 +4791,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ATAN
-          </remark>
+          <remark role="help-topic" condition="ATAN"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ATAN()</primary>
@@ -4731,19 +4803,19 @@
             <literal>ATAN(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the arc tangent of <replaceable>X</replaceable>,
             that is, the value whose tangent is
             <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ATAN
-          </remark>
+          <remark role="help-example" condition="ATAN"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ATAN(2);</userinput>
@@ -4754,10 +4826,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ATAN2
-          </remark>
+          <remark role="help-topic" condition="ATAN2"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ATAN2()</primary>
@@ -4768,6 +4840,10 @@
             <literal>ATAN2(<replaceable>Y</replaceable>,<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the arc tangent of the two variables
             <replaceable>X</replaceable> and
@@ -4778,13 +4854,9 @@
             of the result.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ATAN2
-          </remark>
+          <remark role="help-example" condition="ATAN2"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ATAN(-2,2);</userinput>
@@ -4795,31 +4867,35 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic CEILING CEIL
+          <remark role="help-topic" condition="CEILING"/>
+
+          <remark role="help-keywords">
+            CEIL
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>CEILING()</primary>
             </indexterm>
 
-            <literal>CEILING(<replaceable>X</replaceable>)</literal>,
+            <literal>CEILING(<replaceable>X</replaceable>)</literal>
             <literal>CEIL(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the smallest integer value not less than
             <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic CEILING
-          </remark>
+          <remark role="help-example" condition="CEILING"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CEILING(1.23);</userinput>
@@ -4840,10 +4916,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic COS
-          </remark>
+          <remark role="help-topic" condition="COS"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>COS()</primary>
@@ -4852,18 +4928,18 @@
             <literal>COS(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the cosine of <replaceable>X</replaceable>, where
             <replaceable>X</replaceable> is given in radians.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic COS
-          </remark>
+          <remark role="help-example" condition="COS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT COS(PI());</userinput>
@@ -4872,10 +4948,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic COT
-          </remark>
+          <remark role="help-topic" condition="COT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>COT()</primary>
@@ -4884,17 +4960,17 @@
             <literal>COT(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the cotangent of <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic COT
-          </remark>
+          <remark role="help-example" condition="COT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT COT(12);</userinput>
@@ -4905,10 +4981,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic CRC32
-          </remark>
+          <remark role="help-topic" condition="CRC32"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>CRC32()</primary>
@@ -4917,6 +4993,10 @@
             <literal>CRC32(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Computes a cyclic redundancy check value and returns a
             32-bit unsigned value. The result is <literal>NULL</literal>
@@ -4924,13 +5004,9 @@
             expected be a string and is treated as one if it is not.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic CRC32
-          </remark>
+          <remark role="help-example" condition="CRC32"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CRC32('MySQL');</userinput>
@@ -4943,10 +5019,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic DEGREES
-          </remark>
+          <remark role="help-topic" condition="DEGREES"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>DEGREES()</primary>
@@ -4955,18 +5031,18 @@
             <literal>DEGREES(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the argument <replaceable>X</replaceable>, converted
             from radians to degrees.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic DEGREES
-          </remark>
+          <remark role="help-example" condition="DEGREES"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT DEGREES(PI());</userinput>
@@ -4975,10 +5051,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic EXP
-          </remark>
+          <remark role="help-topic" condition="EXP"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>EXP()</primary>
@@ -4987,19 +5063,19 @@
             <literal>EXP(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the value of <literal>e</literal> (the base of
             natural logarithms) raised to the power of
             <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic EXP
-          </remark>
+          <remark role="help-example" condition="EXP"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT EXP(2);</userinput>
@@ -5010,10 +5086,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic FLOOR
-          </remark>
+          <remark role="help-topic" condition="FLOOR"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>FLOOR()</primary>
@@ -5022,18 +5098,18 @@
             <literal>FLOOR(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the largest integer value not greater than
             <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic FLOOR
-          </remark>
+          <remark role="help-example" condition="FLOOR"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT FLOOR(1.23);</userinput>
@@ -5063,10 +5139,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic LN
-          </remark>
+          <remark role="help-topic" condition="LN"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>LN()</primary>
@@ -5075,18 +5151,18 @@
             <literal>LN(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the natural logarithm of
             <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic LN
-          </remark>
+          <remark role="help-example" condition="LN"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LN(2);</userinput>
@@ -5103,31 +5179,31 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic LOG
-          </remark>
+          <remark role="help-topic" condition="LOG"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>LOG()</primary>
             </indexterm>
 
-            <literal>LOG(<replaceable>X</replaceable>)</literal>,
+            <literal>LOG(<replaceable>X</replaceable>)</literal>
             <literal>LOG(<replaceable>B</replaceable>,<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             If called with one parameter, this function returns the
             natural logarithm of <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic LOG
-          </remark>
+          <remark role="help-example" condition="LOG"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LOG(2);</userinput>
@@ -5158,10 +5234,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic LOG2
-          </remark>
+          <remark role="help-topic" condition="LOG2"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>LOG2()</primary>
@@ -5170,18 +5246,18 @@
             <literal>LOG2(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the base-2 logarithm of
             <literal><replaceable>X</replaceable></literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic LOG2
-          </remark>
+          <remark role="help-example" condition="LOG2"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LOG2(65536);</userinput>
@@ -5200,10 +5276,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic LOG10
-          </remark>
+          <remark role="help-topic" condition="LOG10"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>LOG10()</primary>
@@ -5212,18 +5288,18 @@
             <literal>LOG10(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the base-10 logarithm of
             <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic LOG10
-          </remark>
+          <remark role="help-example" condition="LOG10"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LOG10(2);</userinput>
@@ -5236,10 +5312,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic % MOD
+          <remark role="help-topic" condition="%"/>
+
+          <remark role="help-keywords">
+            MOD
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>MOD()</primary>
@@ -5263,24 +5343,24 @@
 
             <literal>MOD(<replaceable>N</replaceable>,<replaceable>M</replaceable>)</literal>
             , <literal><replaceable>N</replaceable> %
-            <replaceable>M</replaceable></literal>,
+            <replaceable>M</replaceable></literal>
             <literal><replaceable>N</replaceable> MOD
             <replaceable>M</replaceable></literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Modulo operation. Returns the remainder of
             <replaceable>N</replaceable> divided by
             <replaceable>M</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic %
-          </remark>
+          <remark role="help-example" condition="%"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MOD(234, 10);</userinput>
@@ -5324,10 +5404,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic PI
-          </remark>
+          <remark role="help-topic" condition="PI"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>PI()</primary>
@@ -5336,19 +5416,19 @@
             <literal>PI()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the value of PI. The default number of decimals
             displayed is five, but MySQL internally uses the full
             double-precision value for PI.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic PI
-          </remark>
+          <remark role="help-example" condition="PI"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT PI();</userinput>
@@ -5359,10 +5439,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic POWER POW
+          <remark role="help-topic" condition="POWER"/>
+
+          <remark role="help-keywords">
+            POW
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>POW()</primary>
@@ -5377,18 +5461,18 @@
             <literal>POWER(<replaceable>X</replaceable>,<replaceable>Y</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the value of <replaceable>X</replaceable> raised to
             the power of <replaceable>Y</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic POWER
-          </remark>
+          <remark role="help-example" condition="POWER"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT POW(2,2);</userinput>
@@ -5399,10 +5483,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic RADIANS
-          </remark>
+          <remark role="help-topic" condition="RADIANS"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>RADIANS()</primary>
@@ -5411,18 +5495,18 @@
             <literal>RADIANS(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the argument <replaceable>X</replaceable>, converted
             from degrees to radians.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic RADIANS
-          </remark>
+          <remark role="help-example" condition="RADIANS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT RADIANS(90);</userinput>
@@ -5431,19 +5515,23 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic RAND
-          </remark>
+          <remark role="help-topic" condition="RAND"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>RAND()</primary>
             </indexterm>
 
-            <literal>RAND()</literal>,
+            <literal>RAND()</literal>
             <literal>RAND(<replaceable>N</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns a random floating-point value in the range from
             <literal>0</literal> to <literal>1.0</literal>. If an
@@ -5452,13 +5540,9 @@
             sequence).
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic RAND
-          </remark>
+          <remark role="help-example" condition="RAND"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT RAND();</userinput>
@@ -5511,19 +5595,23 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ROUND
-          </remark>
+          <remark role="help-topic" condition="ROUND"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ROUND()</primary>
             </indexterm>
 
-            <literal>ROUND(<replaceable>X</replaceable>)</literal>,
+            <literal>ROUND(<replaceable>X</replaceable>)</literal>
             <literal>ROUND(<replaceable>X</replaceable>,<replaceable>D</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the argument <replaceable>X</replaceable>, rounded
             to the nearest integer. With two arguments, returns
@@ -5534,13 +5622,9 @@
             point of the value <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ROUND
-          </remark>
+          <remark role="help-example" condition="ROUND"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ROUND(-1.23);</userinput>
@@ -5630,10 +5714,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SIGN
-          </remark>
+          <remark role="help-topic" condition="SIGN"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SIGN()</primary>
@@ -5642,6 +5726,10 @@
             <literal>SIGN(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the sign of the argument as <literal>-1</literal>,
             <literal>0</literal>, or <literal>1</literal>, depending on
@@ -5649,13 +5737,9 @@
             positive.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic SIGN
-          </remark>
+          <remark role="help-example" condition="SIGN"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SIGN(-32);</userinput>
@@ -5668,10 +5752,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SIN
-          </remark>
+          <remark role="help-topic" condition="SIN"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SIN()</primary>
@@ -5680,18 +5764,18 @@
             <literal>SIN(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the sine of <replaceable>X</replaceable>, where
             <replaceable>X</replaceable> is given in radians.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic SIN
-          </remark>
+          <remark role="help-example" condition="SIN"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SIN(PI());</userinput>
@@ -5700,10 +5784,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SQRT
-          </remark>
+          <remark role="help-topic" condition="SQRT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SQRT()</primary>
@@ -5712,18 +5796,18 @@
             <literal>SQRT(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the non-negative square root of
             <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic SQRT
-          </remark>
+          <remark role="help-example" condition="SQRT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SQRT(4);</userinput>
@@ -5734,10 +5818,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic TAN
-          </remark>
+          <remark role="help-topic" condition="TAN"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>TAN()</primary>
@@ -5746,18 +5830,18 @@
             <literal>TAN(<replaceable>X</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the tangent of <replaceable>X</replaceable>, where
             <replaceable>X</replaceable> is given in radians.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic TAN
-          </remark>
+          <remark role="help-example" condition="TAN"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TAN(PI()+1);</userinput>
@@ -5766,10 +5850,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic TRUNCATE
-          </remark>
+          <remark role="help-topic" condition="TRUNCATE"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>TRUNCATE()</primary>
@@ -5778,6 +5862,10 @@
             <literal>TRUNCATE(<replaceable>X</replaceable>,<replaceable>D</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the number <replaceable>X</replaceable>, truncated
             to <replaceable>D</replaceable> decimals. If
@@ -5788,13 +5876,9 @@
             decimal point of the value <replaceable>X</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic TRUNCATE
-          </remark>
+          <remark role="help-example" condition="TRUNCATE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TRUNCATE(1.223,1);</userinput>
@@ -5846,9 +5930,7 @@
 
     <title id="title-date-and-time-functions">&title-date-and-time-functions;</title>
 
-    <remark>
-      help_category Date and Time Functions@Functions
-    </remark>
+    <remark role="help-category" condition="Date and Time Functions@Functions"/>
 
     <indexterm type="function">
       <primary>date and time functions</primary>
@@ -5928,10 +6010,10 @@
     <itemizedlist>
 
       <listitem>
-        <remark>
-          description_for_help_topic ADDDATE
-        </remark>
+        <remark role="help-topic" condition="ADDDATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>ADDDATE()</primary>
@@ -5939,10 +6021,14 @@
 
           <literal>ADDDATE(<replaceable>date</replaceable>,INTERVAL
           <replaceable>expr</replaceable>
-          <replaceable>type</replaceable>)</literal>,
+          <replaceable>type</replaceable>)</literal>
           <literal>ADDDATE(<replaceable>expr</replaceable>,<replaceable>days</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           When invoked with the <literal>INTERVAL</literal> form of the
           second argument, <literal>ADDDATE()</literal> is a synonym for
@@ -5972,16 +6058,14 @@
         -&gt; '1998-02-02'
 </programlisting>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic ADDTIME
-        </remark>
+        <remark role="help-topic" condition="ADDTIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>ADDTIME()</primary>
@@ -5990,8 +6074,12 @@
           <literal>ADDTIME(<replaceable>expr</replaceable>,<replaceable>expr2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
 <!--  TODO: DESCRIPTION. Depends on SAP/MySQL mode. -->
 
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>ADDTIME()</literal> adds
           <replaceable>expr2</replaceable> to
@@ -6001,13 +6089,9 @@
           expression.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic ADDTIME
-        </remark>
+        <remark role="help-example" condition="ADDTIME"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ADDTIME('1997-12-31 23:59:59.999999',</userinput>
@@ -6023,10 +6107,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CONVERT_TZ
-        </remark>
+        <remark role="help-topic" condition="CONVERT_TZ"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CONVERT_TZ()</primary>
@@ -6035,6 +6119,10 @@
           <literal>CONVERT_TZ(<replaceable>dt</replaceable>,<replaceable>from_tz</replaceable>,<replaceable>to_tz</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>CONVERT_TZ()</literal> converts a datetime value
           <replaceable>dt</replaceable> from time zone given by
@@ -6045,9 +6133,7 @@
           <literal>NULL</literal> if the arguments are invalid.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
         <para>
           If the value falls out of the supported range of the
@@ -6057,9 +6143,7 @@
           <xref linkend="date-and-time-type-overview"/>.
         </para>
 
-        <remark>
-          example_for_help_topic CONVERT_TZ
-        </remark>
+        <remark role="help-example" condition="CONVERT_TZ"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CONVERT_TZ('2004-01-01 12:00:00','GMT','MET');</userinput>
@@ -6081,10 +6165,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CURDATE
-        </remark>
+        <remark role="help-topic" condition="CURDATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CURDATE()</primary>
@@ -6093,6 +6177,10 @@
           <literal>CURDATE()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the current date as a value in
           <literal>'YYYY-MM-DD'</literal> or <literal>YYYYMMDD</literal>
@@ -6100,13 +6188,9 @@
           or numeric context.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic CURDATE
-        </remark>
+        <remark role="help-example" condition="CURDATE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CURDATE();</userinput>
@@ -6117,35 +6201,37 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CURRENT_DATE
-        </remark>
+        <remark role="help-topic" condition="CURRENT_DATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CURRENT_DATE</primary>
           </indexterm>
 
-          <literal>CURRENT_DATE</literal>,
+          <literal>CURRENT_DATE</literal>
           <literal>CURRENT_DATE()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>CURRENT_DATE</literal> and
           <literal>CURRENT_DATE()</literal> are synonyms for
           <literal>CURDATE()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CURTIME
-        </remark>
+        <remark role="help-topic" condition="CURTIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CURTIME()</primary>
@@ -6154,6 +6240,10 @@
           <literal>CURTIME()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the current time as a value in
           <literal>'HH:MM:SS'</literal> or <literal>HHMMSS</literal>
@@ -6161,13 +6251,9 @@
           or numeric context.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic CURTIME
-        </remark>
+        <remark role="help-example" condition="CURTIME"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CURTIME();</userinput>
@@ -6178,60 +6264,68 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CURRENT_TIME
-        </remark>
+        <remark role="help-topic" condition="CURRENT_TIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CURRENT_TIME</primary>
           </indexterm>
 
-          <literal>CURRENT_TIME</literal>,
+          <literal>CURRENT_TIME</literal>
           <literal>CURRENT_TIME()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>CURRENT_TIME</literal> and
           <literal>CURRENT_TIME()</literal> are synonyms for
           <literal>CURTIME()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CURRENT_TIMESTAMP
-        </remark>
+        <remark role="help-topic" condition="CURRENT_TIMESTAMP"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CURRENT_TIMESTAMP</primary>
           </indexterm>
 
-          <literal>CURRENT_TIMESTAMP</literal>,
+          <literal>CURRENT_TIMESTAMP</literal>
           <literal>CURRENT_TIMESTAMP()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>CURRENT_TIMESTAMP</literal> and
           <literal>CURRENT_TIMESTAMP()</literal> are synonyms for
           <literal>NOW()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DATE function DATE
+        <remark role="help-topic" condition="DATE function"/>
+
+        <remark role="help-keywords">
+          DATE
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DATE()</primary>
@@ -6240,18 +6334,18 @@
           <literal>DATE(<replaceable>expr</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Extracts the date part of the date or datetime expression
           <replaceable>expr</replaceable>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic DATE function
-        </remark>
+        <remark role="help-example" condition="DATE function"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT DATE('2003-12-31 01:02:03');</userinput>
@@ -6264,10 +6358,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DATEDIFF
-        </remark>
+        <remark role="help-topic" condition="DATEDIFF"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DATEDIFF()</primary>
@@ -6276,8 +6370,12 @@
           <literal>DATEDIFF(<replaceable>expr</replaceable>,<replaceable>expr2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
 <!--  TODO: DESCRIPTION. Depends on SAP/MySQL mode. -->
 
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>DATEDIFF()</literal> returns the number of days
           between the start date <replaceable>expr</replaceable> and the
@@ -6288,13 +6386,9 @@
           calculation.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic DATEDIFF
-        </remark>
+        <remark role="help-example" condition="DATEDIFF"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT DATEDIFF('1997-12-31 23:59:59','1997-12-30');</userinput>
@@ -6309,13 +6403,14 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DATE OPERATIONS DATE DATE_ADD
-          DATE_SUB SECOND MINUTE HOUR DAY MONTH YEAR MINUTE_SECOND
-          HOUR_MINUTE DAY_HOUR YEAR_MONTH HOUR_SECOND DAY_MINUTE
-          DAY_SECOND INTERVAL
+        <remark role="help-topic" condition="DATE OPERATIONS"/>
+
+        <remark role="help-keywords">
+          DATE DATE_ADD
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DATE_ADD()</primary>
@@ -6327,12 +6422,16 @@
 
           <literal>DATE_ADD(<replaceable>date</replaceable>,INTERVAL
           <replaceable>expr</replaceable>
-          <replaceable>type</replaceable>)</literal>,
+          <replaceable>type</replaceable>)</literal>
           <literal>DATE_SUB(<replaceable>date</replaceable>,INTERVAL
           <replaceable>expr</replaceable>
           <replaceable>type</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           These functions perform date arithmetic.
           <replaceable>date</replaceable> is a
@@ -6346,9 +6445,7 @@
           the expression should be interpreted.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
         <para>
           The <literal>INTERVAL</literal> keyword and the
@@ -6514,9 +6611,7 @@
           or datetime value from an interval. (See examples below.)
         </para>
 
-        <remark>
-          example_for_help_topic DATE OPERATIONS
-        </remark>
+        <remark role="help-example" condition="DATE OPERATIONS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT '1997-12-31 23:59:59' + INTERVAL 1 SECOND;</userinput>
@@ -6594,10 +6689,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DATE_FORMAT
-        </remark>
+        <remark role="help-topic" condition="DATE_FORMAT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DATE_FORMAT()</primary>
@@ -6606,10 +6701,19 @@
           <literal>DATE_FORMAT(<replaceable>date</replaceable>,<replaceable>format</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Formats the <replaceable>date</replaceable> value according to
-          the <replaceable>format</replaceable> string. The following
-          specifiers may be used in the
+          the <replaceable>format</replaceable> string.
+        </para>
+
+        <remark role="help-description-end"/>
+
+        <para>
+          The following specifiers may be used in the
           <replaceable>format</replaceable> string:
         </para>
 
@@ -6790,14 +6894,8 @@
           <literal>'2004-00-00'</literal> to be stored as of MySQL 3.23.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-example" condition="DATE_FORMAT"/>
 
-        <remark>
-          example_for_help_topic DATE_FORMAT
-        </remark>
-
 <programlisting>
 mysql&gt; <userinput>SELECT DATE_FORMAT('1997-10-04 22:23:00', '%W %M %Y');</userinput>
         -&gt; 'Saturday October 1997'
@@ -6815,10 +6913,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DAY
-        </remark>
+        <remark role="help-topic" condition="DAY"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DAY()</primary>
@@ -6827,22 +6925,24 @@
           <literal>DAY(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>DAY()</literal> is a synonym for
           <literal>DAYOFMONTH()</literal>. It is available as of MySQL
           4.1.1.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DAYNAME
-        </remark>
+        <remark role="help-topic" condition="DAYNAME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DAYNAME()</primary>
@@ -6851,18 +6951,18 @@
           <literal>DAYNAME(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the name of the weekday for
           <replaceable>date</replaceable>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic DAYNAME
-        </remark>
+        <remark role="help-example" condition="DAYNAME"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT DAYNAME('1998-02-05');</userinput>
@@ -6871,10 +6971,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DAYOFMONTH
-        </remark>
+        <remark role="help-topic" condition="DAYOFMONTH"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DAYOFMONTH()</primary>
@@ -6883,19 +6983,19 @@
           <literal>DAYOFMONTH(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the day of the month for
           <replaceable>date</replaceable>, in the range
           <literal>1</literal> to <literal>31</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic DAYOFMONTH
-        </remark>
+        <remark role="help-example" condition="DAYOFMONTH"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT DAYOFMONTH('1998-02-03');</userinput>
@@ -6904,10 +7004,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DAYOFWEEK
-        </remark>
+        <remark role="help-topic" condition="DAYOFWEEK"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DAYOFWEEK()</primary>
@@ -6916,6 +7016,10 @@
           <literal>DAYOFWEEK(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the weekday index for <replaceable>date</replaceable>
           (<literal>1</literal> = Sunday, <literal>2</literal> = Monday,
@@ -6923,13 +7027,9 @@
           correspond to the ODBC standard.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic DAYOFWEEK
-        </remark>
+        <remark role="help-example" condition="DAYOFWEEK"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT DAYOFWEEK('1998-02-03');</userinput>
@@ -6938,10 +7038,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic DAYOFYEAR
-        </remark>
+        <remark role="help-topic" condition="DAYOFYEAR"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>DAYOFYEAR()</primary>
@@ -6950,19 +7050,19 @@
           <literal>DAYOFYEAR(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the day of the year for
           <replaceable>date</replaceable>, in the range
           <literal>1</literal> to <literal>366</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic DAYOFYEAR
-        </remark>
+        <remark role="help-example" condition="DAYOFYEAR"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT DAYOFYEAR('1998-02-03');</userinput>
@@ -6971,10 +7071,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic EXTRACT
-        </remark>
+        <remark role="help-topic" condition="EXTRACT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>EXTRACT()</primary>
@@ -6984,6 +7084,10 @@
           <replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           The <literal>EXTRACT()</literal> function uses the same kinds
           of interval type specifiers as <literal>DATE_ADD()</literal>
@@ -6991,13 +7095,9 @@
           date rather than performing date arithmetic.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic EXTRACT
-        </remark>
+        <remark role="help-example" condition="EXTRACT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT EXTRACT(YEAR FROM '1999-07-02');</userinput>
@@ -7017,10 +7117,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic FROM_DAYS
-        </remark>
+        <remark role="help-topic" condition="FROM_DAYS"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>FROM_DAYS()</primary>
@@ -7029,18 +7129,18 @@
           <literal>FROM_DAYS(<replaceable>N</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Given a daynumber <replaceable>N</replaceable>, returns a
           <literal>DATE</literal> value.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic FROM_DAYS
-        </remark>
+        <remark role="help-example" condition="FROM_DAYS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT FROM_DAYS(729669);</userinput>
@@ -7056,10 +7156,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic FROM_UNIXTIME
-        </remark>
+        <remark role="help-topic" condition="FROM_UNIXTIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>FROM_UNIXTIME()</primary>
@@ -7070,6 +7170,10 @@
           <literal>FROM_UNIXTIME(<replaceable>unix_timestamp</replaceable>,<replaceable>format</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a representation of the
           <replaceable>unix_timestamp</replaceable> argument as a value
@@ -7078,17 +7182,6 @@
           the function is used in a string or numeric context.
         </para>
 
-        <remark>
-          example_for_help_topic FROM_UNIXTIME
-        </remark>
-
-<programlisting>
-mysql&gt; <userinput>SELECT FROM_UNIXTIME(875996580);</userinput>
-        -&gt; '1997-10-04 22:23:00'
-mysql&gt; <userinput>SELECT FROM_UNIXTIME(875996580) + 0;</userinput>
-        -&gt; 19971004222300
-</programlisting>
-
         <para>
           If <replaceable>format</replaceable> is given, the result is
           formatted according to the <replaceable>format</replaceable>
@@ -7097,15 +7190,20 @@
           <literal>DATE_FORMAT()</literal> function.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic FROM_UNIXTIME
-        </remark>
+        <remark role="help-example" condition="FROM_UNIXTIME"/>
 
 <programlisting>
+mysql&gt; <userinput>SELECT FROM_UNIXTIME(875996580);</userinput>
+        -&gt; '1997-10-04 22:23:00'
+mysql&gt; <userinput>SELECT FROM_UNIXTIME(875996580) + 0;</userinput>
+        -&gt; 19971004222300
+</programlisting>
+
+        <remark role="help-example" condition="FROM_UNIXTIME"/>
+
+<programlisting>
 mysql&gt; <userinput>SELECT FROM_UNIXTIME(UNIX_TIMESTAMP(),</userinput>
     -&gt;                      <userinput>'%Y %D %M %h:%i:%s %x');</userinput>
         -&gt; '2003 6th August 06:22:58 2003'
@@ -7113,10 +7211,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic GET_FORMAT
-        </remark>
+        <remark role="help-topic" condition="GET_FORMAT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>GET_FORMAT()</primary>
@@ -7126,12 +7224,18 @@
           'EUR'|'USA'|'JIS'|'ISO'|'INTERNAL')</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a format string. This function is useful in
           combination with the <literal>DATE_FORMAT()</literal> and the
           <literal>STR_TO_DATE()</literal> functions.
         </para>
 
+        <remark role="help-description-end"/>
+
 <!--
   Following is commented out because not yet implemented:
 
@@ -7237,14 +7341,8 @@
   the function returns @code{NULL}.
 -->
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-example" condition="GET_FORMAT"/>
 
-        <remark>
-          example_for_help_topic GET_FORMAT
-        </remark>
-
 <programlisting>
 mysql&gt; <userinput>SELECT DATE_FORMAT('2003-10-03',GET_FORMAT(DATE,'EUR'));</userinput>
         -&gt; '03.10.2003'
@@ -7267,10 +7365,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic HOUR
-        </remark>
+        <remark role="help-topic" condition="HOUR"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>HOUR()</primary>
@@ -7279,19 +7377,19 @@
           <literal>HOUR(<replaceable>time</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the hour for <replaceable>time</replaceable>. The
           range of the return value is <literal>0</literal> to
           <literal>23</literal> for time-of-day values.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic HOUR
-        </remark>
+        <remark role="help-example" condition="HOUR"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT HOUR('10:05:03');</userinput>
@@ -7311,10 +7409,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LAST_DAY
-        </remark>
+        <remark role="help-topic" condition="LAST_DAY"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LAST_DAY()</primary>
@@ -7323,19 +7421,19 @@
           <literal>LAST_DAY(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Takes a date or datetime value and returns the corresponding
           value for the last day of the month. Returns
           <literal>NULL</literal> if the argument is invalid.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic LAST_DAY
-        </remark>
+        <remark role="help-example" condition="LAST_DAY"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LAST_DAY('2003-02-05');</userinput>
@@ -7354,27 +7452,29 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LOCALTIME
-        </remark>
+        <remark role="help-topic" condition="LOCALTIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LOCALTIME</primary>
           </indexterm>
 
-          <literal>LOCALTIME</literal>, <literal>LOCALTIME()</literal>
+          <literal>LOCALTIME</literal> <literal>LOCALTIME()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>LOCALTIME</literal> and
           <literal>LOCALTIME()</literal> are synonyms for
           <literal>NOW()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
         <para>
           They were added in MySQL 4.0.6.
@@ -7382,28 +7482,30 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic LOCALTIMESTAMP
-        </remark>
+        <remark role="help-topic" condition="LOCALTIMESTAMP"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>LOCALTIMESTAMP</primary>
           </indexterm>
 
-          <literal>LOCALTIMESTAMP</literal>,
+          <literal>LOCALTIMESTAMP</literal>
           <literal>LOCALTIMESTAMP()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>LOCALTIMESTAMP</literal> and
           <literal>LOCALTIMESTAMP()</literal> are synonyms for
           <literal>NOW()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
         <para>
           They were added in MySQL 4.0.6.
@@ -7411,10 +7513,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic MAKEDATE
-        </remark>
+        <remark role="help-topic" condition="MAKEDATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MAKEDATE()</primary>
@@ -7423,19 +7525,19 @@
           <literal>MAKEDATE(<replaceable>year</replaceable>,<replaceable>dayofyear</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a date, given year and day-of-year values.
           <replaceable>dayofyear</replaceable> must be greater than 0 or
           the result is <literal>NULL</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic MAKEDATE
-        </remark>
+        <remark role="help-example" condition="MAKEDATE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MAKEDATE(2001,31), MAKEDATE(2001,32);</userinput>
@@ -7452,10 +7554,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic MAKETIME
-        </remark>
+        <remark role="help-topic" condition="MAKETIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MAKETIME()</primary>
@@ -7464,6 +7566,10 @@
           <literal>MAKETIME(<replaceable>hour</replaceable>,<replaceable>minute</replaceable>,<replaceable>second</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns a time value calculated from the
           <replaceable>hour</replaceable>,
@@ -7471,13 +7577,9 @@
           <replaceable>second</replaceable> arguments.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic MAKETIME
-        </remark>
+        <remark role="help-example" condition="MAKETIME"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MAKETIME(12,15,30);</userinput>
@@ -7490,10 +7592,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic MICROSECOND
-        </remark>
+        <remark role="help-topic" condition="MICROSECOND"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MICROSECOND()</primary>
@@ -7502,19 +7604,19 @@
           <literal>MICROSECOND(<replaceable>expr</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the microseconds from the time or datetime expression
           <replaceable>expr</replaceable> as a number in the range from
           <literal>0</literal> to <literal>999999</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic MICROSECOND
-        </remark>
+        <remark role="help-example" condition="MICROSECOND"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MICROSECOND('12:00:00.123456');</userinput>
@@ -7530,10 +7632,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic MINUTE
-        </remark>
+        <remark role="help-topic" condition="MINUTE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MINUTE()</primary>
@@ -7542,18 +7644,18 @@
           <literal>MINUTE(<replaceable>time</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the minute for <replaceable>time</replaceable>, in the
           range <literal>0</literal> to <literal>59</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic MINUTE
-        </remark>
+        <remark role="help-example" condition="MINUTE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MINUTE('98-02-03 10:05:03');</userinput>
@@ -7562,10 +7664,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic MONTH
-        </remark>
+        <remark role="help-topic" condition="MONTH"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MONTH()</primary>
@@ -7574,18 +7676,18 @@
           <literal>MONTH(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the month for <replaceable>date</replaceable>, in the
           range <literal>1</literal> to <literal>12</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic MONTH
-        </remark>
+        <remark role="help-example" condition="MONTH"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MONTH('1998-02-03');</userinput>
@@ -7594,10 +7696,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic MONTHNAME
-        </remark>
+        <remark role="help-topic" condition="MONTHNAME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MONTHNAME()</primary>
@@ -7606,18 +7708,18 @@
           <literal>MONTHNAME(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the full name of the month for
           <replaceable>date</replaceable>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic MONTHNAME
-        </remark>
+        <remark role="help-example" condition="MONTHNAME"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MONTHNAME('1998-02-05');</userinput>
@@ -7626,10 +7728,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic NOW
-        </remark>
+        <remark role="help-topic" condition="NOW"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>NOW()</primary>
@@ -7638,6 +7740,10 @@
           <literal>NOW()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the current date and time as a value in
           <literal>'YYYY-MM-DD HH:MM:SS'</literal> or
@@ -7645,13 +7751,9 @@
           the function is used in a string or numeric context.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic NOW
-        </remark>
+        <remark role="help-example" condition="NOW"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT NOW();</userinput>
@@ -7669,10 +7771,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic PERIOD_ADD
-        </remark>
+        <remark role="help-topic" condition="PERIOD_ADD"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>PERIOD_ADD()</primary>
@@ -7681,6 +7783,10 @@
           <literal>PERIOD_ADD(<replaceable>P</replaceable>,<replaceable>N</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Adds <replaceable>N</replaceable> months to period
           <replaceable>P</replaceable> (in the format
@@ -7690,13 +7796,9 @@
           <emphasis>not</emphasis> a date value.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic PERIOD_ADD
-        </remark>
+        <remark role="help-example" condition="PERIOD_ADD"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT PERIOD_ADD(9801,2);</userinput>
@@ -7705,10 +7807,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic PERIOD_DIFF
-        </remark>
+        <remark role="help-topic" condition="PERIOD_DIFF"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>PERIOD_DIFF()</primary>
@@ -7717,6 +7819,10 @@
           <literal>PERIOD_DIFF(<replaceable>P1</replaceable>,<replaceable>P2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the number of months between periods
           <replaceable>P1</replaceable> and
@@ -7728,13 +7834,9 @@
           date values.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic PERIOD_DIFF
-        </remark>
+        <remark role="help-example" condition="PERIOD_DIFF"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT PERIOD_DIFF(9802,199703);</userinput>
@@ -7743,10 +7845,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic QUARTER
-        </remark>
+        <remark role="help-topic" condition="QUARTER"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>QUARTER()</primary>
@@ -7755,19 +7857,19 @@
           <literal>QUARTER(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the quarter of the year for
           <replaceable>date</replaceable>, in the range
           <literal>1</literal> to <literal>4</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic QUARTER
-        </remark>
+        <remark role="help-example" condition="QUARTER"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT QUARTER('98-04-01');</userinput>
@@ -7776,10 +7878,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SECOND
-        </remark>
+        <remark role="help-topic" condition="SECOND"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SECOND()</primary>
@@ -7788,18 +7890,18 @@
           <literal>SECOND(<replaceable>time</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the second for <replaceable>time</replaceable>, in the
           range <literal>0</literal> to <literal>59</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic SECOND
-        </remark>
+        <remark role="help-example" condition="SECOND"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SECOND('10:05:03');</userinput>
@@ -7808,10 +7910,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SEC_TO_TIME
-        </remark>
+        <remark role="help-topic" condition="SEC_TO_TIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SEC_TO_TIME()</primary>
@@ -7820,6 +7922,10 @@
           <literal>SEC_TO_TIME(<replaceable>seconds</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the <replaceable>seconds</replaceable> argument,
           converted to hours, minutes, and seconds, as a value in
@@ -7828,13 +7934,9 @@
           or numeric context.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic SEC_TO_TIME
-        </remark>
+        <remark role="help-example" condition="SEC_TO_TIME"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SEC_TO_TIME(2378);</userinput>
@@ -7847,10 +7949,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic STR_TO_DATE
-        </remark>
+        <remark role="help-topic" condition="STR_TO_DATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>STR_TO_DATE()</primary>
@@ -7859,6 +7961,10 @@
           <literal>STR_TO_DATE(<replaceable>str</replaceable>,<replaceable>format</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           This is the reverse function of the
           <literal>DATE_FORMAT()</literal> function. It takes a string
@@ -7902,13 +8008,9 @@
           value also produces a warning.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic STR_TO_DATE
-        </remark>
+        <remark role="help-example" condition="STR_TO_DATE"/>
 
 <programlisting>
 <!--  next example commented out until format string becomes optional -->
@@ -7950,10 +8052,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SUBDATE
-        </remark>
+        <remark role="help-topic" condition="SUBDATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SUBDATE()</primary>
@@ -7961,10 +8063,14 @@
 
           <literal>SUBDATE(<replaceable>date</replaceable>,INTERVAL
           <replaceable>expr</replaceable>
-          <replaceable>type</replaceable>)</literal>,
+          <replaceable>type</replaceable>)</literal>
           <literal>SUBDATE(<replaceable>expr</replaceable>,<replaceable>days</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           When invoked with the <literal>INTERVAL</literal> form of the
           second argument, <literal>SUBDATE()</literal> is a synonym for
@@ -8006,16 +8112,14 @@
 -&gt; 2004-10-18
 </programlisting>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SUBTIME
-        </remark>
+        <remark role="help-topic" condition="SUBTIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SUBTIME()</primary>
@@ -8024,8 +8128,12 @@
           <literal>SUBTIME(<replaceable>expr</replaceable>,<replaceable>expr2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
 <!--  TODO: DESCRIPTION. Depends on SAP/MySQL mode. -->
 
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>SUBTIME()</literal> subtracts
           <replaceable>expr2</replaceable> from
@@ -8035,13 +8143,9 @@
           expression.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic SUBTIME
-        </remark>
+        <remark role="help-example" condition="SUBTIME"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SUBTIME('1997-12-31 23:59:59.999999',</userinput>
@@ -8057,10 +8161,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic SYSDATE
-        </remark>
+        <remark role="help-topic" condition="SYSDATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>SYSDATE()</primary>
@@ -8069,6 +8173,10 @@
           <literal>SYSDATE()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the current date and time as a value in
           <literal>'YYYY-MM-DD HH:MM:SS'</literal> or
@@ -8084,16 +8192,18 @@
           <literal>NOW()</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TIME function TIME
+        <remark role="help-topic" condition="TIME function"/>
+
+        <remark role="help-keywords">
+          TIME
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TIME()</primary>
@@ -8102,18 +8212,18 @@
           <literal>TIME(<replaceable>expr</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Extracts the time part of the time or datetime expression
           <replaceable>expr</replaceable> and returns it as a string.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic TIME function
-        </remark>
+        <remark role="help-example" condition="TIME function"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TIME('2003-12-31 01:02:03');</userinput>
@@ -8128,10 +8238,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TIMEDIFF
-        </remark>
+        <remark role="help-topic" condition="TIMEDIFF"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TIMEDIFF()</primary>
@@ -8140,8 +8250,12 @@
           <literal>TIMEDIFF(<replaceable>expr</replaceable>,<replaceable>expr2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
 <!--  TODO: DESCRIPTION. Depends on SAP/MySQL mode. -->
 
+        <remark role="help-description-begin"/>
+
         <para>
           <literal>TIMEDIFF()</literal> returns the time between the
           start time <replaceable>expr</replaceable> and the end time
@@ -8151,13 +8265,9 @@
           expressions, but both must be of the same type.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic TIMEDIFF
-        </remark>
+        <remark role="help-example" condition="TIMEDIFF"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TIMEDIFF('2000:01:01 00:00:00',</userinput>
@@ -8174,10 +8284,14 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TIMESTAMP function TIMESTAMP
+        <remark role="help-topic" condition="TIMESTAMP function"/>
+
+        <remark role="help-keywords">
+          TIMESTAMP
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TIMESTAMP()</primary>
@@ -8188,6 +8302,10 @@
           <literal>TIMESTAMP(<replaceable>expr</replaceable>,<replaceable>expr2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           With one argument, returns the date or datetime expression
           <replaceable>expr</replaceable> as a datetime value. With two
@@ -8197,13 +8315,9 @@
           datetime value.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic TIMESTAMP function
-        </remark>
+        <remark role="help-example" condition="TIMESTAMP function"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TIMESTAMP('2003-12-31');</userinput>
@@ -8218,10 +8332,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TIMESTAMPADD
-        </remark>
+        <remark role="help-topic" condition="TIMESTAMPADD"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TIMESTAMPADD()</primary>
@@ -8230,6 +8344,10 @@
           <literal>TIMESTAMPADD(<replaceable>interval</replaceable>,<replaceable>int_expr</replaceable>,<replaceable>datetime_expr</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Adds the integer expression
           <replaceable>int_expr</replaceable> to the date or datetime
@@ -8251,13 +8369,9 @@
           are legal.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic TIMESTAMPADD function
-        </remark>
+        <remark role="help-example" condition="TIMESTAMPADD function"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TIMESTAMPADD(MINUTE,1,'2003-01-02');</userinput>
@@ -8273,10 +8387,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TIMESTAMPDIFF
-        </remark>
+        <remark role="help-topic" condition="TIMESTAMPDIFF"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TIMESTAMPDIFF()</primary>
@@ -8285,6 +8399,10 @@
           <literal>TIMESTAMPDIFF(<replaceable>interval</replaceable>,<replaceable>datetime_expr1</replaceable>,<replaceable>datetime_expr2</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the integer difference between the date or datetime
           expressions <replaceable>datetime_expr1</replaceable> and
@@ -8296,13 +8414,9 @@
           <literal>TIMESTAMPADD()</literal> function.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic TIMESTAMPDIFF function
-        </remark>
+        <remark role="help-example" condition="TIMESTAMPDIFF function"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TIMESTAMPDIFF(MONTH,'2003-02-01','2003-05-01');</userinput>
@@ -8318,10 +8432,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TIME_FORMAT
-        </remark>
+        <remark role="help-topic" condition="TIME_FORMAT"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TIME_FORMAT()</primary>
@@ -8330,6 +8444,10 @@
           <literal>TIME_FORMAT(<replaceable>time</replaceable>,<replaceable>format</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           This is used like the <literal>DATE_FORMAT()</literal>
           function, but the <replaceable>format</replaceable> string may
@@ -8338,9 +8456,7 @@
           <literal>NULL</literal> value or <literal>0</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
         <para>
           If the <replaceable>time</replaceable> value contains an hour
@@ -8358,10 +8474,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TIME_TO_SEC
-        </remark>
+        <remark role="help-topic" condition="TIME_TO_SEC"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TIME_TO_SEC()</primary>
@@ -8370,18 +8486,18 @@
           <literal>TIME_TO_SEC(<replaceable>time</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the <replaceable>time</replaceable> argument,
           converted to seconds.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic TIME_TO_SEC
-        </remark>
+        <remark role="help-example" condition="TIME_TO_SEC"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TIME_TO_SEC('22:23:00');</userinput>
@@ -8392,10 +8508,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic TO_DAYS
-        </remark>
+        <remark role="help-topic" condition="TO_DAYS"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>TO_DAYS()</primary>
@@ -8404,18 +8520,18 @@
           <literal>TO_DAYS(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Given a date <replaceable>date</replaceable>, returns a
           daynumber (the number of days since year 0).
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic TO_DAYS
-        </remark>
+        <remark role="help-example" condition="TO_DAYS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT TO_DAYS(950501);</userinput>
@@ -8451,19 +8567,23 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UNIX_TIMESTAMP
-        </remark>
+        <remark role="help-topic" condition="UNIX_TIMESTAMP"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UNIX_TIMESTAMP()</primary>
           </indexterm>
 
-          <literal>UNIX_TIMESTAMP()</literal>,
+          <literal>UNIX_TIMESTAMP()</literal>
           <literal>UNIX_TIMESTAMP(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           If called with no argument, returns a Unix timestamp (seconds
           since <literal>'1970-01-01 00:00:00'</literal> GMT) as an
@@ -8478,13 +8598,9 @@
           <literal>YYYYMMDD</literal> in local time.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic UNIX_TIMESTAMP
-        </remark>
+        <remark role="help-example" condition="UNIX_TIMESTAMP"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UNIX_TIMESTAMP();</userinput>
@@ -8515,18 +8631,22 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UTC_DATE
-        </remark>
+        <remark role="help-topic" condition="UTC_DATE"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UTC_DATE()</primary>
           </indexterm>
 
-          <literal>UTC_DATE</literal>, <literal>UTC_DATE()</literal>
+          <literal>UTC_DATE</literal> <literal>UTC_DATE()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the current UTC date as a value in
           <literal>'YYYY-MM-DD'</literal> or <literal>YYYYMMDD</literal>
@@ -8534,13 +8654,9 @@
           or numeric context.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic UTC_DATE
-        </remark>
+        <remark role="help-example" condition="UTC_DATE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UTC_DATE(), UTC_DATE() + 0;</userinput>
@@ -8553,18 +8669,22 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UTC_TIME
-        </remark>
+        <remark role="help-topic" condition="UTC_TIME"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UTC_TIME()</primary>
           </indexterm>
 
-          <literal>UTC_TIME</literal>, <literal>UTC_TIME()</literal>
+          <literal>UTC_TIME</literal> <literal>UTC_TIME()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the current UTC time as a value in
           <literal>'HH:MM:SS'</literal> or <literal>HHMMSS</literal>
@@ -8572,13 +8692,9 @@
           or numeric context.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic UTC_TIME
-        </remark>
+        <remark role="help-example" condition="UTC_TIME"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UTC_TIME(), UTC_TIME() + 0;</userinput>
@@ -8591,19 +8707,23 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic UTC_TIMESTAMP
-        </remark>
+        <remark role="help-topic" condition="UTC_TIMESTAMP"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>UTC_TIMESTAMP()</primary>
           </indexterm>
 
-          <literal>UTC_TIMESTAMP</literal>,
+          <literal>UTC_TIMESTAMP</literal>
           <literal>UTC_TIMESTAMP()</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the current UTC date and time as a value in
           <literal>'YYYY-MM-DD HH:MM:SS'</literal> or
@@ -8611,13 +8731,9 @@
           the function is used in a string or numeric context.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic UTC_TIMESTAMP
-        </remark>
+        <remark role="help-example" condition="UTC_TIMESTAMP"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UTC_TIMESTAMP(), UTC_TIMESTAMP() + 0;</userinput>
@@ -8631,10 +8747,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic WEEK
-        </remark>
+        <remark role="help-topic" condition="WEEK"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>WEEK()</primary>
@@ -8643,6 +8759,10 @@
           <literal>WEEK(<replaceable>date</replaceable>[,<replaceable>mode</replaceable>])</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           The function returns the week number for
           <replaceable>date</replaceable>. The two-argument form of
@@ -8657,6 +8777,8 @@
           <xref linkend="server-system-variables"/>.
         </para>
 
+        <remark role="help-description-end"/>
+
         <para>
           The following table describes how the
           <replaceable>mode</replaceable> argument works:
@@ -8739,14 +8861,8 @@
           <literal>4</literal> and above can be used as of MySQL 4.0.17.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-example" condition="WEEK"/>
 
-        <remark>
-          example_for_help_topic WEEK
-        </remark>
-
 <programlisting>
 mysql&gt; <userinput>SELECT WEEK('1998-02-20');</userinput>
         -&gt; 7
@@ -8820,10 +8936,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic WEEKDAY
-        </remark>
+        <remark role="help-topic" condition="WEEKDAY"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>WEEKDAY()</primary>
@@ -8832,19 +8948,19 @@
           <literal>WEEKDAY(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the weekday index for <replaceable>date</replaceable>
           (<literal>0</literal> = Monday, <literal>1</literal> =
           Tuesday, ... <literal>6</literal> = Sunday).
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic WEEKDAY
-        </remark>
+        <remark role="help-example" condition="WEEKDAY"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT WEEKDAY('1998-02-03 22:23:00');</userinput>
@@ -8855,10 +8971,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic WEEKOFYEAR
-        </remark>
+        <remark role="help-topic" condition="WEEKOFYEAR"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>WEEKOFYEAR()</primary>
@@ -8867,6 +8983,10 @@
           <literal>WEEKOFYEAR(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the calendar week of the date as a number in the range
           from <literal>1</literal> to <literal>53</literal>. It is a
@@ -8874,13 +8994,9 @@
           <literal>WEEK(<replaceable>date</replaceable>,3)</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic WEEKOFYEAR
-        </remark>
+        <remark role="help-example" condition="WEEKOFYEAR"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT WEEKOFYEAR('1998-02-20');</userinput>
@@ -8894,10 +9010,10 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic YEAR
-        </remark>
+        <remark role="help-topic" condition="YEAR"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>YEAR()</primary>
@@ -8906,18 +9022,18 @@
           <literal>YEAR(<replaceable>date</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns the year for <replaceable>date</replaceable>, in the
           range <literal>1000</literal> to <literal>9999</literal>.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic YEAR
-        </remark>
+        <remark role="help-example" condition="YEAR"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT YEAR('98-02-03');</userinput>
@@ -8926,19 +9042,23 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic YEARWEEK
-        </remark>
+        <remark role="help-topic" condition="YEARWEEK"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>YEARWEEK()</primary>
           </indexterm>
 
-          <literal>YEARWEEK(<replaceable>date</replaceable>)</literal>,
+          <literal>YEARWEEK(<replaceable>date</replaceable>)</literal>
           <literal>YEARWEEK(<replaceable>date</replaceable>,<replaceable>start</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           Returns year and week for a date. The
           <replaceable>start</replaceable> argument works exactly like
@@ -8948,13 +9068,9 @@
           the last week of the year.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic YEARWEEK
-        </remark>
+        <remark role="help-example" condition="YEARWEEK"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT YEARWEEK('1987-01-01');</userinput>
@@ -9083,9 +9199,7 @@
 
     <title id="title-fulltext-search">&title-fulltext-search;</title>
 
-    <remark>
-      help_category String Functions@Functions
-    </remark>
+    <remark role="help-category" condition="String Functions@Functions"/>
 
     <indexterm>
       <primary>searching</primary>
@@ -9103,11 +9217,14 @@
     <itemizedlist>
 
       <listitem>
-        <remark>
-          description_for_help_topic MATCH AGAINST MATCH AGAINST BOOLEAN
-          IN MODE MATCH AGAINST QUERY EXPANSION WITH
+        <remark role="help-topic" condition="MATCH AGAINST"/>
+
+        <remark role="help-keywords">
+          MATCH AGAINST BOOLEAN
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>MATCH ... AGAINST()</primary>
@@ -9119,6 +9236,10 @@
           WITH QUERY EXPANSION])</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           As of MySQL 3.23.23, MySQL has support for full-text indexing
           and searching. A full-text index in MySQL is an index of type
@@ -9137,9 +9258,7 @@
           slower.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
         <para>
           Constraints on full-text searching are listed in
@@ -9275,14 +9394,8 @@
       full-text search code only once.
     </para>
 
-    <remark>
-      help_category String Functions@Functions
-    </remark>
+    <remark role="help-example" condition="MATCH AGAINST"/>
 
-    <remark>
-      example_for_help_topic MATCH AGAINST
-    </remark>
-
 <programlisting>
 mysql&gt; <userinput>SELECT id, body, MATCH (title,body) AGAINST</userinput>
     -&gt; <userinput>('Security implications of running MySQL as root') AS score</userinput>
@@ -10989,10 +11102,10 @@
     <itemizedlist>
 
       <listitem>
-        <remark>
-          description_for_help_topic BINARY operator
-        </remark>
+        <remark role="help-topic" condition="BINARY operator"/>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>BINARY</primary>
@@ -11001,6 +11114,10 @@
           <literal>BINARY</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           The <literal>BINARY</literal> operator casts the string
           following it to a binary string. This is an easy way to force
@@ -11012,13 +11129,9 @@
           significant.
         </para>
 
-        <remark>
-          end_description_for_help_topic
-        </remark>
+        <remark role="help-description-end"/>
 
-        <remark>
-          example_for_help_topic BINARY operator
-        </remark>
+        <remark role="help-example" condition="BINARY operator"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 'a' = 'A';</userinput>
@@ -11104,11 +11217,14 @@
       </listitem>
 
       <listitem>
-        <remark>
-          description_for_help_topic CAST CONVERT SIGNED UNSIGNED BINARY
-          CHAR DATE DATETIME TIME
+        <remark role="help-topic" condition="CAST"/>
+
+        <remark role="help-keywords">
+          CONVERT SIGNED UNSIGNED BINARY
         </remark>
 
+        <remark role="help-syntax-begin"/>
+
         <para>
           <indexterm type="function">
             <primary>CAST</primary>
@@ -11119,12 +11235,16 @@
           </indexterm>
 
           <literal>CAST(<replaceable>expr</replaceable> AS
-          <replaceable>type</replaceable>)</literal>,
+          <replaceable>type</replaceable>)</literal>
           <literal>CONVERT(<replaceable>expr</replaceable>,<replaceable>type</replaceable>)</literal>
           , <literal>CONVERT(<replaceable>expr</replaceable> USING
           <replaceable>transcoding_name</replaceable>)</literal>
         </para>
 
+        <remark role="help-syntax-end"/>
+
+        <remark role="help-description-begin"/>
+
         <para>
           The <literal>CAST()</literal> and <literal>CONVERT()</literal>
           functions can be used to take a value of one type and produce
@@ -11227,6 +11347,8 @@
 <programlisting>
 SELECT CONVERT('abc' USING utf8);
 </programlisting>
+
+        <remark role="help-description-end"/>
       </listitem>
 
     </itemizedlist>
@@ -11237,10 +11359,6 @@
       statement:
     </para>
 
-    <remark>
-      end_description_for_help_topic
-    </remark>
-
 <programlisting>
 CREATE TABLE new_table SELECT CAST('2000-01-01' AS DATE);
 </programlisting>
@@ -11253,9 +11371,7 @@
       results in a lexical sort:
     </para>
 
-    <remark>
-      example_for_help_topic CAST
-    </remark>
+    <remark role="help-example" condition="CAST"/>
 
 <programlisting>
 SELECT <replaceable>enum_col</replaceable> FROM <replaceable>tbl_name</replaceable> ORDER BY CAST(<replaceable>enum_col</replaceable> AS CHAR);
@@ -11390,10 +11506,6 @@
 
     <title id="title-other-functions">&title-other-functions;</title>
 
-    <remark>
-      help_category Bit Functions@Functions
-    </remark>
-
     <section id="bit-functions">
 
       <title id="title-bit-functions">&title-bit-functions;</title>
@@ -11412,6 +11524,8 @@
         <secondary>bit</secondary>
       </indexterm>
 
+      <remark role="help-category" condition="Bit Functions@Functions"/>
+
       <para>
         MySQL uses <literal>BIGINT</literal> (64-bit) arithmetic for bit
         operations, so these operators have a maximum range of 64 bits.
@@ -11420,10 +11534,10 @@
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic |
-          </remark>
+          <remark role="help-topic" condition="|"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>| (bitwise OR)</primary>
@@ -11437,17 +11551,17 @@
             <literal>|</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Bitwise OR:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic |
-          </remark>
+          <remark role="help-example" condition="|"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 29 | 15;</userinput>
@@ -11460,10 +11574,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &amp;
-          </remark>
+          <remark role="help-topic" condition="&amp;"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>&amp; (bitwise AND)</primary>
@@ -11477,17 +11591,17 @@
             <literal>&amp;</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Bitwise AND:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &amp;
-          </remark>
+          <remark role="help-example" condition="&amp;"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 29 &amp; 15;</userinput>
@@ -11500,10 +11614,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ^
-          </remark>
+          <remark role="help-topic" condition="^"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>^ (bitwise XOR)</primary>
@@ -11517,17 +11631,17 @@
             <literal>^</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Bitwise XOR:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ^
-          </remark>
+          <remark role="help-example" condition="^"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 ^ 1;</userinput>
@@ -11548,10 +11662,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &lt;&lt;
-          </remark>
+          <remark role="help-topic" condition="&lt;&lt;"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>&lt;&lt; (left shift)</primary>
@@ -11560,18 +11674,18 @@
             <literal>&lt;&lt;</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Shifts a longlong (<literal>BIGINT</literal>) number to the
             left.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &lt;&lt;
-          </remark>
+          <remark role="help-example" condition="&lt;&lt;"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 1 &lt;&lt; 2;</userinput>
@@ -11584,10 +11698,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic &gt;&gt;
-          </remark>
+          <remark role="help-topic" condition="&gt;&gt;"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>&gt;&gt; (right shift)</primary>
@@ -11596,18 +11710,18 @@
             <literal>&gt;&gt;</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Shifts a longlong (<literal>BIGINT</literal>) number to the
             right.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic &gt;&gt;
-          </remark>
+          <remark role="help-example" condition="&gt;&gt;"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 4 &gt;&gt; 2;</userinput>
@@ -11620,10 +11734,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ~
-          </remark>
+          <remark role="help-topic" condition="~"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>~</primary>
@@ -11632,17 +11746,17 @@
             <literal>~</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Invert all bits.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ~
-          </remark>
+          <remark role="help-example" condition="~"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT 5 &amp; ~1;</userinput>
@@ -11655,10 +11769,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic BIT_COUNT
-          </remark>
+          <remark role="help-topic" condition="BIT_COUNT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>BIT_COUNT()</primary>
@@ -11667,18 +11781,18 @@
             <literal>BIT_COUNT(<replaceable>N</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the number of bits that are set in the argument
             <replaceable>N</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic BIT_COUNT
-          </remark>
+          <remark role="help-example" condition="BIT_COUNT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT BIT_COUNT(29);</userinput>
@@ -11703,9 +11817,7 @@
         <secondary>encryption</secondary>
       </indexterm>
 
-      <remark>
-        help_category Encryption Functions@Functions
-      </remark>
+      <remark role="help-category" condition="Encryption Functions@Functions"/>
 
       <para>
         The functions in this section encrypt and decrypt data values.
@@ -11720,10 +11832,14 @@
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic AES_DECRYPT AES_ENCRYPT
+          <remark role="help-topic" condition="AES_DECRYPT"/>
+
+          <remark role="help-keywords">
+            AES_ENCRYPT
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>AES_ENCRYPT()</primary>
@@ -11738,6 +11854,10 @@
             <literal>AES_DECRYPT(<replaceable>crypt_str</replaceable>,<replaceable>key_str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             These functions allow encryption and decryption of data
             using the official AES (Advanced Encryption Standard)
@@ -11773,13 +11893,9 @@
             form by modifying your queries:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic AES_DECRYPT
-          </remark>
+          <remark role="help-example" condition="AES_DECRYPT"/>
 
 <programlisting>
 INSERT INTO t VALUES (1,AES_ENCRYPT('text','password'));
@@ -11794,10 +11910,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic DECODE
-          </remark>
+          <remark role="help-topic" condition="DECODE"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>DECODE()</primary>
@@ -11806,6 +11922,10 @@
             <literal>DECODE(<replaceable>crypt_str</replaceable>,<replaceable>pass_str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Decrypts the encrypted string
             <replaceable>crypt_str</replaceable> using
@@ -11814,16 +11934,14 @@
             returned from <literal>ENCODE()</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ENCODE
-          </remark>
+          <remark role="help-topic" condition="ENCODE"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ENCODE()</primary>
@@ -11832,6 +11950,10 @@
             <literal>ENCODE(<replaceable>str</replaceable>,<replaceable>pass_str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Encrypt <replaceable>str</replaceable> using
             <replaceable>pass_str</replaceable> as the password. To
@@ -11844,16 +11966,14 @@
             column, use a <literal>BLOB</literal> column type.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic DES_DECRYPT
-          </remark>
+          <remark role="help-topic" condition="DES_DECRYPT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>DES_DECRYPT()</primary>
@@ -11862,6 +11982,10 @@
             <literal>DES_DECRYPT(<replaceable>crypt_str</replaceable>[,<replaceable>key_str</replaceable>])</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Decrypts a string encrypted with
             <literal>DES_ENCRYPT()</literal>. On error, this function
@@ -11897,9 +12021,7 @@
             <replaceable>crypt_str</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
           <para>
             <literal>DES_DECRYPT()</literal> was added in MySQL 4.0.1.
@@ -11907,10 +12029,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic DES_ENCRYPT
-          </remark>
+          <remark role="help-topic" condition="DES_ENCRYPT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>DES_ENCRYPT()</primary>
@@ -11919,12 +12041,18 @@
             <literal>DES_ENCRYPT(<replaceable>str</replaceable>[,(<replaceable>key_num</replaceable>|<replaceable>key_str</replaceable>)])</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Encrypts the string with the given key using the Triple-DES
             algorithm. On error, this function returns
             <literal>NULL</literal>.
           </para>
 
+          <remark role="help-description-end"/>
+
           <para>
             Note that this function works only if MySQL has been
             configured with SSL support. See
@@ -11985,17 +12113,11 @@
             (8-(<replaceable>orig_len</replaceable> % 8))+1</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
-
           <para>
             Each line in the DES key file has the following format:
           </para>
 
-          <remark>
-            example_for_help_topic DES_ENCRYPT
-          </remark>
+          <remark role="help-example" condition="DES_ENCRYPT"/>
 
 <programlisting>
 <replaceable>key_num</replaceable> <replaceable>des_key_str</replaceable>
@@ -12036,10 +12158,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ENCRYPT
-          </remark>
+          <remark role="help-topic" condition="ENCRYPT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ENCRYPT()</primary>
@@ -12048,6 +12170,10 @@
             <literal>ENCRYPT(<replaceable>str</replaceable>[,<replaceable>salt</replaceable>])</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Encrypt <replaceable>str</replaceable> using the Unix
             <literal>crypt()</literal> system call. The
@@ -12058,13 +12184,9 @@
             is given, a random value is used.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ENCRYPT
-          </remark>
+          <remark role="help-example" condition="ENCRYPT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT ENCRYPT('hello');</userinput>
@@ -12090,10 +12212,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic MD5
-          </remark>
+          <remark role="help-topic" condition="MD5"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>MD5()</primary>
@@ -12102,6 +12224,10 @@
             <literal>MD5(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Calculates an MD5 128-bit checksum for the string. The value
             is returned as a binary string of 32 hex digits, or
@@ -12110,13 +12236,9 @@
             be used as a hash key.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic MD5
-          </remark>
+          <remark role="help-example" condition="MD5"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT MD5('testing');</userinput>
@@ -12141,10 +12263,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic OLD_PASSWORD
-          </remark>
+          <remark role="help-topic" condition="OLD_PASSWORD"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>OLD_PASSWORD()</primary>
@@ -12153,6 +12275,10 @@
             <literal>OLD_PASSWORD(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             <literal>OLD_PASSWORD()</literal> is available as of MySQL
             4.1, when the implementation of
@@ -12162,13 +12288,15 @@
             <literal>PASSWORD()</literal>.
             <xref linkend="password-hashing"/>.
           </para>
+
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic PASSWORD
-          </remark>
+          <remark role="help-topic" condition="PASSWORD"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>PASSWORD()</primary>
@@ -12177,6 +12305,10 @@
             <literal>PASSWORD(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Calculates and returns a password string from the plaintext
             password <replaceable>str</replaceable>, or
@@ -12187,13 +12319,9 @@
             <literal>user</literal> grant table.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic PASSWORD
-          </remark>
+          <remark role="help-example" condition="PASSWORD"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT PASSWORD('badpwd');</userinput>
@@ -12229,10 +12357,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SHA SHA1
+          <remark role="help-topic" condition="SHA"/>
+
+          <remark role="help-keywords">
+            SHA1
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SHA1()</primary>
@@ -12242,10 +12374,14 @@
               <primary>SHA()</primary>
             </indexterm>
 
-            <literal>SHA1(<replaceable>str</replaceable>)</literal>,
+            <literal>SHA1(<replaceable>str</replaceable>)</literal>
             <literal>SHA(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Calculates an SHA1 160-bit checksum for the string, as
             described in RFC 3174 (Secure Hash Algorithm). The value is
@@ -12256,13 +12392,9 @@
             cryptographically safe function for storing passwords.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic SHA
-          </remark>
+          <remark role="help-example" condition="SHA"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SHA1('abc');</userinput>
@@ -12294,17 +12426,15 @@
         <secondary>information</secondary>
       </indexterm>
 
-      <remark>
-        help_category Information Functions@Functions
-      </remark>
+      <remark role="help-category" condition="Information Functions@Functions"/>
 
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic BENCHMARK
-          </remark>
+          <remark role="help-topic" condition="BENCHMARK"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>BENCHMARK()</primary>
@@ -12313,6 +12443,10 @@
             <literal>BENCHMARK(<replaceable>count</replaceable>,<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             The <literal>BENCHMARK()</literal> function executes the
             expression <replaceable>expr</replaceable> repeatedly
@@ -12323,13 +12457,9 @@
             reports query execution times:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic BENCHMARK
-          </remark>
+          <remark role="help-example" condition="BENCHMARK"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT BENCHMARK(1000000,ENCODE('hello','goodbye'));</userinput>
@@ -12351,10 +12481,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic CHARSET
-          </remark>
+          <remark role="help-topic" condition="CHARSET"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>CHARSET()</primary>
@@ -12363,17 +12493,17 @@
             <literal>CHARSET(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the character set of the string argument.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic CHARSET
-          </remark>
+          <remark role="help-example" condition="CHARSET"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CHARSET('abc');</userinput>
@@ -12390,10 +12520,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic COERCIBILITY
-          </remark>
+          <remark role="help-topic" condition="COERCIBILITY"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>COERCIBILITY()</primary>
@@ -12402,18 +12532,18 @@
             <literal>COERCIBILITY(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the collation coercibility value of the string
             argument.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic COERCIBILITY
-          </remark>
+          <remark role="help-example" condition="COERCIBILITY"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT COERCIBILITY('abc' COLLATE latin1_swedish_ci);</userinput>
@@ -12525,10 +12655,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic COLLATION
-          </remark>
+          <remark role="help-topic" condition="COLLATION"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>COLLATION()</primary>
@@ -12537,18 +12667,18 @@
             <literal>COLLATION(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the collation for the character set of the string
             argument.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic COLLATION
-          </remark>
+          <remark role="help-example" condition="COLLATION"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT COLLATION('abc');</userinput>
@@ -12563,10 +12693,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic CONNECTION_ID
-          </remark>
+          <remark role="help-topic" condition="CONNECTION_ID"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>CONNECTION_ID()</primary>
@@ -12575,18 +12705,18 @@
             <literal>CONNECTION_ID()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the connection ID (thread ID) for the connection.
             Every connection has its own unique ID.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic CONNECTION_ID
-          </remark>
+          <remark role="help-example" condition="CONNECTION_ID"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT CONNECTION_ID();</userinput>
@@ -12600,10 +12730,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic CURRENT_USER
-          </remark>
+          <remark role="help-topic" condition="CURRENT_USER"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>CURRENT_USER()</primary>
@@ -12612,6 +12742,10 @@
             <literal>CURRENT_USER()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the username and hostname combination that the
             current session was authenticated as. This value corresponds
@@ -12627,13 +12761,9 @@
             from the value of <literal>USER()</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic CURRENT_USER
-          </remark>
+          <remark role="help-example" condition="CURRENT_USER"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT USER();</userinput>
@@ -12664,10 +12794,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic DATABASE
-          </remark>
+          <remark role="help-topic" condition="DATABASE"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>DATABASE()</primary>
@@ -12676,19 +12806,19 @@
             <literal>DATABASE()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the default (current) database name. As of MySQL
             4.1, the string has the <literal>utf8</literal> character
             set.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic DATABASE
-          </remark>
+          <remark role="help-example" condition="DATABASE"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT DATABASE();</userinput>
@@ -12704,10 +12834,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic FOUND_ROWS
-          </remark>
+          <remark role="help-topic" condition="FOUND_ROWS"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>FOUND_ROWS()</primary>
@@ -12720,6 +12850,10 @@
             <literal>FOUND_ROWS()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             A <literal>SELECT</literal> statement may include a
             <literal>LIMIT</literal> clause to restrict the number of
@@ -12732,13 +12866,9 @@
             <literal>FOUND_ROWS()</literal> afterward:
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic FOUND_ROWS
-          </remark>
+          <remark role="help-example" condition="FOUND_ROWS"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT SQL_CALC_FOUND_ROWS * FROM <replaceable>tbl_name</replaceable></userinput>
@@ -12853,31 +12983,31 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic LAST_INSERT_ID
-          </remark>
+          <remark role="help-topic" condition="LAST_INSERT_ID"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>LAST_INSERT_ID([<replaceable>expr</replaceable>])</primary>
             </indexterm>
 
-            <literal>LAST_INSERT_ID()</literal>,
+            <literal>LAST_INSERT_ID()</literal>
             <literal>LAST_INSERT_ID(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the last automatically generated value that was
             inserted into an <literal>AUTO_INCREMENT</literal> column.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic LAST_INSERT_ID
-          </remark>
+          <remark role="help-example" condition="LAST_INSERT_ID"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT LAST_INSERT_ID();</userinput>
@@ -12999,10 +13129,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic ROW_COUNT
-          </remark>
+          <remark role="help-topic" condition="ROW_COUNT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>ROW_COUNT()</primary>
@@ -13011,6 +13141,10 @@
             <literal>ROW_COUNT()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             <literal>ROW_COUNT()</literal> returns the number of rows
             updated, inserted, or deleted by the preceding statement.
@@ -13019,13 +13153,9 @@
             the <literal>mysql_affected_rows()</literal> C API function.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic ROW_COUNT
-          </remark>
+          <remark role="help-example" condition="ROW_COUNT"/>
 
 <programlisting>
 mysql&gt; <userinput>INSERT INTO t VALUES(1),(2),(3);</userinput>
@@ -13058,10 +13188,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SCHEMA
-          </remark>
+          <remark role="help-topic" condition="SCHEMA"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SCHEMA()</primary>
@@ -13070,21 +13200,23 @@
             <literal>SCHEMA()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             This function is a synonym for
             <literal>DATABASE()</literal>. It was added in MySQL 5.0.2.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SESSION_USER
-          </remark>
+          <remark role="help-topic" condition="SESSION_USER"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SESSION_USER()</primary>
@@ -13093,21 +13225,23 @@
             <literal>SESSION_USER()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             <literal>SESSION_USER()</literal> is a synonym for
             <literal>USER()</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SYSTEM_USER
-          </remark>
+          <remark role="help-topic" condition="SYSTEM_USER"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SYSTEM_USER()</primary>
@@ -13116,21 +13250,23 @@
             <literal>SYSTEM_USER()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             <literal>SYSTEM_USER()</literal> is a synonym for
             <literal>USER()</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic USER
-          </remark>
+          <remark role="help-topic" condition="USER"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>USER()</primary>
@@ -13139,17 +13275,17 @@
             <literal>USER()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the current MySQL username and hostname.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic USER
-          </remark>
+          <remark role="help-example" condition="USER"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT USER();</userinput>
@@ -13189,10 +13325,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic VERSION
-          </remark>
+          <remark role="help-topic" condition="VERSION"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>VERSION()</primary>
@@ -13201,19 +13337,19 @@
             <literal>VERSION()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns a string that indicates the MySQL server version. As
             of MySQL 4.1, the string has the <literal>utf8</literal>
             character set.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic VERSION
-          </remark>
+          <remark role="help-example" condition="VERSION"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT VERSION();</userinput>
@@ -13243,17 +13379,15 @@
         <secondary>miscellaneous</secondary>
       </indexterm>
 
-      <remark>
-        help_category Miscellaneous Functions@Functions
-      </remark>
+      <remark role="help-category" condition="Miscellaneous Functions@Functions"/>
 
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic DEFAULT
-          </remark>
+          <remark role="help-topic" condition="DEFAULT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>DEFAULT()</primary>
@@ -13262,19 +13396,19 @@
             <literal>DEFAULT(<replaceable>col_name</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the default value for a table column. Starting from
             MySQL 5.0.2, you get an error if the column doesn't have a
             default value.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic DEFAULT
-          </remark>
+          <remark role="help-example" condition="DEFAULT"/>
 
 <programlisting>
 mysql&gt; <userinput>UPDATE t SET i = DEFAULT(i)+1 WHERE id &lt; 100;</userinput>
@@ -13286,10 +13420,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic FORMAT
-          </remark>
+          <remark role="help-topic" condition="FORMAT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>FORMAT()</primary>
@@ -13298,6 +13432,10 @@
             <literal>FORMAT(<replaceable>X</replaceable>,<replaceable>D</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Formats the number <replaceable>X</replaceable> to a format
             like <literal>'#,###,###.##'</literal>, rounded to
@@ -13307,13 +13445,9 @@
             fractional part.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic FORMAT
-          </remark>
+          <remark role="help-example" condition="FORMAT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT FORMAT(12332.123456, 4);</userinput>
@@ -13326,10 +13460,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic GET_LOCK
-          </remark>
+          <remark role="help-topic" condition="GET_LOCK"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm>
               <primary>timeout</primary>
@@ -13342,6 +13476,10 @@
             <literal>GET_LOCK(<replaceable>str</replaceable>,<replaceable>timeout</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Tries to obtain a lock with a name given by the string
             <replaceable>str</replaceable>, with a timeout of
@@ -13377,13 +13515,9 @@
             <replaceable>app_name.str</replaceable>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic GET_LOCK
-          </remark>
+          <remark role="help-example" condition="GET_LOCK"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT GET_LOCK('lock1',10);</userinput>
@@ -13407,10 +13541,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic INET_ATON
-          </remark>
+          <remark role="help-topic" condition="INET_ATON"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>INET_ATON()</primary>
@@ -13419,6 +13553,10 @@
             <literal>INET_ATON(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Given the dotted-quad representation of a network address as
             a string, returns an integer that represents the numeric
@@ -13426,13 +13564,9 @@
             addresses.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic INET_ATON
-          </remark>
+          <remark role="help-example" condition="INET_ATON"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT INET_ATON('209.207.224.40');</userinput>
@@ -13475,10 +13609,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic INET_NTOA
-          </remark>
+          <remark role="help-topic" condition="INET_NTOA"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>INET_NTOA()</primary>
@@ -13487,18 +13621,18 @@
             <literal>INET_NTOA(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Given a numeric network address (4 or 8 byte), returns the
             dotted-quad representation of the address as a string.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic INET_NTOA
-          </remark>
+          <remark role="help-example" condition="INET_NTOA"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT INET_NTOA(3520061480);</userinput>
@@ -13511,10 +13645,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic IS_FREE_LOCK
-          </remark>
+          <remark role="help-topic" condition="IS_FREE_LOCK"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>IS_FREE_LOCK()</primary>
@@ -13523,6 +13657,10 @@
             <literal>IS_FREE_LOCK(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Checks whether the lock named <replaceable>str</replaceable>
             is free to use (that is, not locked). Returns
@@ -13532,9 +13670,7 @@
             arguments).
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
           <para>
             <literal>IS_FREE_LOCK()</literal> was added in MySQL 4.0.2.
@@ -13542,10 +13678,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic IS_USED_LOCK
-          </remark>
+          <remark role="help-topic" condition="IS_USED_LOCK"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>IS_USED_LOCK()</primary>
@@ -13554,6 +13690,10 @@
             <literal>IS_USED_LOCK(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Checks whether the lock named <replaceable>str</replaceable>
             is in use (that is, locked). If so, it returns the
@@ -13561,9 +13701,7 @@
             Otherwise, it returns <literal>NULL</literal>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
           <para>
             <literal>IS_USED_LOCK()</literal> was added in MySQL 4.1.0.
@@ -13571,10 +13709,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic MASTER_POS_WAIT
-          </remark>
+          <remark role="help-topic" condition="MASTER_POS_WAIT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>MASTER_POS_WAIT()</primary>
@@ -13583,6 +13721,10 @@
             <literal>MASTER_POS_WAIT(<replaceable>log_name</replaceable>,<replaceable>log_pos</replaceable>[,<replaceable>timeout</replaceable>])</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             This function is useful for control of master/slave
             synchronization. It blocks until the slave has read and
@@ -13600,9 +13742,7 @@
             immediately.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
           <para>
             If a <replaceable>timeout</replaceable> value is specified,
@@ -13621,10 +13761,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic RELEASE_LOCK
-          </remark>
+          <remark role="help-topic" condition="RELEASE_LOCK"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>RELEASE_LOCK()</primary>
@@ -13633,6 +13773,10 @@
             <literal>RELEASE_LOCK(<replaceable>str</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Releases the lock named by the string
             <replaceable>str</replaceable> that was obtained with
@@ -13651,16 +13795,14 @@
             <xref linkend="do"/>.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SLEEP
-          </remark>
+          <remark role="help-topic" condition="SLEEP"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SLEEP()</primary>
@@ -13669,6 +13811,10 @@
             <literal>SLEEP(<replaceable>duration</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Sleeps (pauses) for the number of seconds given by the
             <replaceable>duration</replaceable> argument, then returns
@@ -13677,16 +13823,14 @@
             microseconds. This function was added in MySQL 5.0.12.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic UUID
-          </remark>
+          <remark role="help-topic" condition="UUID"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>UUID()</primary>
@@ -13695,6 +13839,10 @@
             <literal>UUID()</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns a Universal Unique Identifier (UUID) generated
             according to <quote>DCE 1.1: Remote Procedure Call</quote>
@@ -13757,13 +13905,9 @@
 
           </itemizedlist>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic UUID
-          </remark>
+          <remark role="help-example" condition="UUID"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT UUID();</userinput>
@@ -13790,11 +13934,6 @@
 
     <title id="title-group-by-functions-and-modifiers">&title-group-by-functions-and-modifiers;</title>
 
-    <remark>
-      help_category Functions and Modifiers for Use with GROUP BY
-      Clauses@Functions
-    </remark>
-
     <section id="group-by-functions">
 
       <title id="title-group-by-functions">&title-group-by-functions;</title>
@@ -13808,6 +13947,8 @@
         <secondary>GROUP BY</secondary>
       </indexterm>
 
+      <remark role="help-category" condition="Functions and Modifiers for Use with GROUP BY"/>
+
       <para>
         This section describes group (aggregate) functions that operate
         on sets of values. Unless otherwise stated, group functions
@@ -13823,10 +13964,14 @@
       <itemizedlist>
 
         <listitem>
-          <remark>
-            description_for_help_topic AVG DISTINCT
+          <remark role="help-topic" condition="AVG"/>
+
+          <remark role="help-keywords">
+            DISTINCT
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>AVG()</primary>
@@ -13844,6 +13989,10 @@
             <replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the average value of
             <literal><replaceable>expr</replaceable></literal>. The
@@ -13857,13 +14006,9 @@
             there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic AVG
-          </remark>
+          <remark role="help-example" condition="AVG"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT student_name, AVG(test_score)</userinput>
@@ -13873,10 +14018,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic BIT_AND
-          </remark>
+          <remark role="help-topic" condition="BIT_AND"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>BIT_AND()</primary>
@@ -13885,15 +14030,17 @@
             <literal>BIT_AND(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the bitwise <literal>AND</literal> of all bits in
             <replaceable>expr</replaceable>. The calculation is
             performed with 64-bit (<literal>BIGINT</literal>) precision.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
           <para>
             As of MySQL 4.0.17, this function returns
@@ -13906,10 +14053,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic BIT_OR
-          </remark>
+          <remark role="help-topic" condition="BIT_OR"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>BIT_OR()</primary>
@@ -13918,15 +14065,17 @@
             <literal>BIT_OR(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the bitwise <literal>OR</literal> of all bits in
             <replaceable>expr</replaceable>. The calculation is
             performed with 64-bit (<literal>BIGINT</literal>) precision.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
           <para>
             This function returns <literal>0</literal> if there were no
@@ -13935,10 +14084,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic BIT_XOR
-          </remark>
+          <remark role="help-topic" condition="BIT_XOR"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>BIT_XOR()</primary>
@@ -13947,15 +14096,17 @@
             <literal>BIT_XOR(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the bitwise <literal>XOR</literal> of all bits in
             <replaceable>expr</replaceable>. The calculation is
             performed with 64-bit (<literal>BIGINT</literal>) precision.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
           <para>
             This function returns <literal>0</literal> if there were no
@@ -13968,10 +14119,10 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic COUNT
-          </remark>
+          <remark role="help-topic" condition="COUNT"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>COUNT()</primary>
@@ -13980,6 +14131,10 @@
             <literal>COUNT(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns a count of the number of non-<literal>NULL</literal>
             values in the rows retrieved by a <literal>SELECT</literal>
@@ -13991,13 +14146,9 @@
             there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic COUNT
-          </remark>
+          <remark role="help-example" condition="COUNT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT student.student_name,COUNT(*)</userinput>
@@ -14037,10 +14188,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic COUNT DISTINCT COUNT DISTINCT
+          <remark role="help-topic" condition="COUNT DISTINCT"/>
+
+          <remark role="help-keywords">
+            DISTINCT COUNT DISTINCT
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>COUNT(DISTINCT)</primary>
@@ -14054,6 +14209,10 @@
             <replaceable>expr</replaceable>,[<replaceable>expr</replaceable>...])</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns a count of the number of different
             non-<literal>NULL</literal> values.
@@ -14064,13 +14223,9 @@
             <literal>0</literal> if there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic COUNT DISTINCT
-          </remark>
+          <remark role="help-example" condition="COUNT DISTINCT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT COUNT(DISTINCT results) FROM student;</userinput>
@@ -14091,11 +14246,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic GROUP_CONCAT DISTINCT SEPARATOR
-            ORDER BY ASC DESC
+          <remark role="help-topic" condition="GROUP_CONCAT"/>
+
+          <remark role="help-keywords">
+            DISTINCT SEPARATOR
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>GROUP_CONCAT()</primary>
@@ -14104,6 +14262,10 @@
             <literal>GROUP_CONCAT(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             This function returns a string result with the concatenated
             non-<literal>NULL</literal> values from a group. It returns
@@ -14119,13 +14281,9 @@
              [SEPARATOR <replaceable>str_val</replaceable>])
 </programlisting>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic GROUP_CONCAT
-          </remark>
+          <remark role="help-example" condition="GROUP_CONCAT"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT student_name,</userinput>
@@ -14213,10 +14371,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic MIN MAX MIN MAX DISTINCT
+          <remark role="help-topic" condition="MIN MAX"/>
+
+          <remark role="help-keywords">
+            MAX MIN MAX DISTINCT
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>MIN()</primary>
@@ -14239,11 +14401,15 @@
             </indexterm>
 
             <literal>MIN([DISTINCT]
-            <replaceable>expr</replaceable>)</literal>,
+            <replaceable>expr</replaceable>)</literal>
             <literal>MAX([DISTINCT]
             <replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the minimum or maximum value of
             <replaceable>expr</replaceable>. <literal>MIN()</literal>
@@ -14262,13 +14428,9 @@
             <literal>NULL</literal> if there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
 
-          <remark>
-            example_for_help_topic MIN MAX
-          </remark>
+          <remark role="help-example" condition="MIN MAX"/>
 
 <programlisting>
 mysql&gt; <userinput>SELECT student_name, MIN(test_score), MAX(test_score)</userinput>
@@ -14287,10 +14449,14 @@
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic STDDEV STD
+          <remark role="help-topic" condition="STDDEV"/>
+
+          <remark role="help-keywords">
+            STD
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>STD()</primary>
@@ -14309,10 +14475,14 @@
               <secondary>with Oracle</secondary>
             </indexterm>
 
-            <literal>STD(<replaceable>expr</replaceable>)</literal>,
+            <literal>STD(<replaceable>expr</replaceable>)</literal>
             <literal>STDDEV(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the population standard deviation of
             <replaceable>expr</replaceable>. This is an extension to
@@ -14327,16 +14497,14 @@
             no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic STDDEV_POP
-          </remark>
+          <remark role="help-topic" condition="STDDEV_POP"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>STDDEV_POP()</primary>
@@ -14345,6 +14513,10 @@
             <literal>STDDEV_POP(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the population standard deviation of
             <replaceable>expr</replaceable> (the square root of
@@ -14359,16 +14531,14 @@
             <literal>NULL</literal> if there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic STDDEV_SAMP
-          </remark>
+          <remark role="help-topic" condition="STDDEV_SAMP"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>STDDEV_SAMP()</primary>
@@ -14377,6 +14547,10 @@
             <literal>STDDEV_SAMP(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the sample standard deviation of
             <replaceable>expr</replaceable> (the square root of
@@ -14389,16 +14563,18 @@
             <literal>NULL</literal> if there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic SUM DISTINCT
+          <remark role="help-topic" condition="SUM"/>
+
+          <remark role="help-keywords">
+            DISTINCT
           </remark>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>SUM()</primary>
@@ -14416,6 +14592,10 @@
             <replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the sum of <replaceable>expr</replaceable>. If the
             return set has no rows, <literal>SUM()</literal> returns
@@ -14429,16 +14609,14 @@
             there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic VAR_POP
-          </remark>
+          <remark role="help-topic" condition="VAR_POP"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>VAR_POP()</primary>
@@ -14447,6 +14625,10 @@
             <literal>VAR_POP(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the population standard variance of
             <replaceable>expr</replaceable>. It considers rows as the
@@ -14462,16 +14644,14 @@
             if there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic VAR_SAMP
-          </remark>
+          <remark role="help-topic" condition="VAR_SAMP"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>VAR_SAMP()</primary>
@@ -14480,6 +14660,10 @@
             <literal>VAR_SAMP(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the sample variance of
             <replaceable>expr</replaceable>. That is, the denominator is
@@ -14492,16 +14676,14 @@
             <literal>NULL</literal> if there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
         <listitem>
-          <remark>
-            description_for_help_topic VARIANCE
-          </remark>
+          <remark role="help-topic" condition="VARIANCE"/>
 
+          <remark role="help-syntax-begin"/>
+
           <para>
             <indexterm type="function">
               <primary>VARIANCE()</primary>
@@ -14510,6 +14692,10 @@
             <literal>VARIANCE(<replaceable>expr</replaceable>)</literal>
           </para>
 
+          <remark role="help-syntax-end"/>
+
+          <remark role="help-description-begin"/>
+
           <para>
             Returns the population standard variance of
             <replaceable>expr</replaceable>. This is an extension to
@@ -14523,9 +14709,7 @@
             <literal>NULL</literal> if there were no matching rows.
           </para>
 
-          <remark>
-            end_description_for_help_topic
-          </remark>
+          <remark role="help-description-end"/>
         </listitem>
 
       </itemizedlist>
@@ -14874,14 +15058,6 @@
         the following query:
       </para>
 
-      <remark>
-        end_description_for_help_topic
-      </remark>
-
-      <remark>
-        example_for_help_topic BIT_AND
-      </remark>
-
 <programlisting>
 mysql&gt; <userinput>SELECT order.custid, customer.name, MAX(payments)</userinput>
     -&gt;        <userinput>FROM order,customer</userinput>

Thread
svn commit - mysqldoc@docsrva: r73 - in trunk: . refmanpaul17 Oct