Author: jstephens
Date: 2006-08-24 01:53:44 +0200 (Thu, 24 Aug 2006)
New Revision: 3093
Log:
Sample output for some of the utilities
Warning about affects of ndb_drop_index for MySQL server
Modified:
trunk/refman-5.1/ndb-utilities.xml
Modified: trunk/refman-5.1/ndb-utilities.xml
===================================================================
--- trunk/refman-5.1/ndb-utilities.xml 2006-08-23 23:39:26 UTC (rev 3092)
+++ trunk/refman-5.1/ndb-utilities.xml 2006-08-23 23:53:44 UTC (rev 3093)
Changed blocks: 6, Lines Added: 64, Lines Deleted: 6; 3447 bytes
@@ -337,7 +337,10 @@
<para>
<emphasis role="bold">Description</emphasis>: Drops the specified
- index from an <literal>NDB</literal> table.
+ index from an <literal>NDB</literal> table. <emphasis>It is
+ recommended that you use this utility only as an example for
+ writing NDB API applications</emphasis> — see the Warning
+ later in this section for details.
</para>
<para>
@@ -360,10 +363,12 @@
</para>
<para>
- <emphasis role="bold">Warning</emphasis>: Operations performed on
- Cluster table indexes are not visible to MySQL. If you use this
- program to drop an index, then try to access the table from an SQL
- node, an error results:
+ <emphasis role="bold">Warning</emphasis>: <emphasis>Operations
+ performed on Cluster table indexes using the NDB API are not
+ visible to MySQL and make the table unusable by a MySQL
+ server</emphasis>. If you use this program to drop an index, then
+ try to access the table from an SQL node, an error results, as
+ shown here:
</para>
<programlisting>
@@ -399,6 +404,13 @@
<errortext>ERROR 1296 (HY000): Got error 4243 'Index not found' from NDBCLUSTER</errortext>
</programlisting>
+ <para>
+ In such a case, your <emphasis>only</emphasis> option for making
+ the table available to MySQL again is to drop the table and
+ re-create it. You can still use <literal>DROP TABLE</literal> to
+ drop the table.
+ </para>
+
</section>
<section id="mysql-cluster-utility-programs-ndb-drop-table">
@@ -407,7 +419,9 @@
<para>
<emphasis role="bold">Description</emphasis>: Drops the specified
- <literal>NDB</literal> table.
+ <literal>NDB</literal> table. This is extremely fast — an
+ order of magnitude faster than <literal>TRUNCATE</literal> in some
+ cases.
</para>
<para>
@@ -536,6 +550,39 @@
<emphasis role="bold">Additional Options</emphasis>:
</para>
+ <para>
+ <emphasis role="bold">Sample Output</emphasis>:
+ </para>
+
+<programlisting>
+mysql> <userinput>SELECT * FROM fish;</userinput>
++----+-----------+
+| id | name |
++----+-----------+
+| 3 | shark |
+| 6 | puffer |
+| 2 | tuna |
+| 4 | manta ray |
+| 5 | grouper |
+| 1 | guppy |
++----+-----------+
+6 rows in set (0.04 sec)
+</programlisting>
+
+<programlisting>
+jon@monster-zero:/usr/local/mysql/bin> <userinput>./ndb_select_all -c 192.168.0.179 fish -d ctest1</userinput>
+id name
+3 [shark]
+6 [puffer]
+2 [tuna]
+4 [manta ray]
+5 [grouper]
+1 [guppy]
+6 rows returned
+
+NDBT_ProgramExit: 0 - OK
+</programlisting>
+
</section>
<section id="mysql-cluster-utility-programs-ndb-select-count">
@@ -559,6 +606,17 @@
<emphasis role="bold">Additional Options</emphasis>:
</para>
+ <para>
+ <emphasis role="bold">Sample Output</emphasis>:
+ </para>
+
+<programlisting>
+jon@monster-zero:/usr/local/mysql/bin> <userinput>./ndb_select_count -c 192.168.0.179 fish -d ctest1</userinput>
+6 records in table fish
+
+NDBT_ProgramExit: 0 - OK
+</programlisting>
+
</section>
<section id="mysql-cluster-utility-programs-ndb-show-tables">
| Thread |
|---|
| • svn commit - mysqldoc@docsrva: r3093 - trunk/refman-5.1 | jon | 24 Aug |