List:Commits« Previous MessageNext Message »
From:jon Date:October 21 2006 3:22pm
Subject:svn commit - mysqldoc@docsrva: r3693 - trunk/refman-5.0
View as plain text  
Author: jstephens
Date: 2006-10-21 15:22:15 +0200 (Sat, 21 Oct 2006)
New Revision: 3693

Log:

Renaming old-faq.xml to faqs.xml

Turning it into a chapter rather than a section



Added:
   trunk/refman-5.0/faqs.xml
Removed:
   trunk/refman-5.0/old-faq.xml


Added: trunk/refman-5.0/faqs.xml
===================================================================
--- trunk/refman-5.0/faqs.xml	                        (rev 0)
+++ trunk/refman-5.0/faqs.xml	2006-10-21 13:22:15 UTC (rev 3693)
Changed blocks: 1, Lines Added: 1882, Lines Deleted: 0; 44940 bytes

@@ -0,0 +1,1882 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
+"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
+[
+  <!ENTITY % fixedchars.entities  SYSTEM "../refman-common/fixedchars.ent">
+  %fixedchars.entities;
+  <!ENTITY % urls.entities       SYSTEM "../refman-common/urls.ent">
+  %urls.entities;
+  <!ENTITY % versions.entities    SYSTEM "versions.ent">
+  %versions.entities;
+]>
+<chapter id="faqs">
+
+  <title>MySQL &current-series; Technical FAQ</title>
+
+  <section id="faqs-general">
+
+    <title>MySQL &current-series; FAQ &mdash; General</title>
+
+    <qandaset defaultlabel="qanda">
+
+      <qandaentry id="faqs-general-production">
+
+        <question>
+
+          <para>
+            When did MySQL &current-series; become production-ready
+            (GA)?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            MySQL 5.0.15 was released for production use on 19 October
+            2005. We are now working on MySQL 5.1, which is currently in
+            beta.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-subqueries">
+
+        <question>
+
+          <para>
+            Can MySQL &current-series; do subqueries?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. MySQL supports subqueries since version 4.1 See
+            <xref linkend="subqueries"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-multi-table">
+
+        <question>
+
+          <para>
+            Can MySQL &current-series; do multi-table inserts and
+            updates?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. Multi-table <literal>UPDATE</literal> and
+            <literal>DELETE</literal> were actually implemented in MySQL
+            4.0, with enhancements added in MySQL 4.1. See
+            <xref
+              linkend="update"/>, and
+            <xref linkend="delete"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-query-cache">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; have a Query Cache? Does it work
+            on Server, Instance or Database?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. The Query Cache was introduced in MySQL 4.0, and
+            operates on the server level. It caches complete result
+            sets, matched with the original query string. If an exactly
+            identical query is made (which often happens, particularly
+            in web applications), no parsing or execution is necessary,
+            the result is sent directly from the cache. Various tuning
+            options are available. See <xref linkend="query-cache"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-sequences">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; have Sequences?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No. However, MySQL has an <literal>AUTO_INCREMENT</literal>
+            system, which in MySQL &current-series; can also handle
+            inserts in a multi-master replication setup. With the
+            <option>--auto-increment-increment</option> and
+            <option>--auto-increment-offset</option> startup options,
+            you can set each server to generate auto-increment values
+            that don't conflict with other servers. The
+            <option>--auto-increment-increment</option> value should be
+            greater than the number of servers, and each server should
+            have a unique offset.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-now-fractional-seconds">
+
+        <question>
+
+          <para>
+            Does MySQL 5.0 have a <literal>NOW()</literal> function with
+            fractions of seconds?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No. This is on the MySQL roadmap as a <quote>rolling
+            feature</quote>. This means that it is not a flagship
+            feature, but will be implemented, development time
+            permitting. Specific customer demand may change this
+            scheduling.
+          </para>
+
+          <para>
+            However, MySQL does parse time strings with a fractional
+            component. See <xref linkend="time"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-multi-cores">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; work with mutli-core
+            processorsd?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. MySQL is fully multi-threaded, and will make use of
+            multiple CPUs, provided that the operating system supports
+            them.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-myisam-hot-backup">
+
+        <question>
+
+          <para>
+            Is there a hot backup tool for MyISAM like InnoDB Hot
+            Backup?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            This is currently under development for a future MySQL
+            release.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-fk-error-reporting">
+
+        <question>
+
+          <para>
+            Is there any improvement in error reporting when Foreign Key
+            fails (i.e. currently does not report which column and
+            reference failed)?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            The foreign key support in InnoDB has seen improvements in
+            each major version of MySQL. However, global foreign key
+            support (i.e., generically for all storage engines) is
+            scheduled for MySQL 5.2 and should resolve any inadequacies
+            in the current storage engine specific implementation.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-general-acid">
+
+        <question>
+
+          <para>
+            Can MySQL &current-series; perform ACID transactions?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. MySQL has supported transactions for years now, since
+            3.23-Max and all versions 4.0 and above. The InnoDB storage
+            engine offers full ACID transactions with row-level locking,
+            multi-versioning, non-locking repeatable reads, and all four
+            SQL standard isolation levels.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+  <section id="faqs-storage-engines">
+
+    <title>MySQL &current-series; FAQ &mdash; Storage Engines</title>
+
+    <qandaset defaultlabel="qanda">
+
+      <qandaentry id="faqs-storage-engines-new-engines">
+
+        <question>
+
+          <para>
+            What are the new Storage Engines in MySQL &current-series;?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            The <literal>FEDERATED</literal> storage engine, new in My
+            SQL &current-series;, allows the server to access tables in
+            other (remote) servers. See
+            <xref
+              linkend="federated-storage-engine"/>.
+          </para>
+
+          <para>
+            MySQL 4.1 already added other new storage engines, such as
+            ARCHIVE, CSV and NDB (Cluster).
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-storage-engines-archive">
+
+        <question>
+
+          <para>
+            What are the unique benefits of the
+            <literal>ARCHIVE</literal> storage engine?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            The <literal>ARCHIVE</literal> Storage Engine, added in
+            MySQL 4.1, is ideally suited for storing large amounts of
+            data (without indexes) in a very small footprint, and
+            selects using table scans. See
+            <xref
+              linkend="archive-storage-engine"/>, for
+            details.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-storage-engines-new-features">
+
+        <question>
+
+          <para>
+            Do the new features in MySQL &current-series; apply to all
+            storage engines?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            The general new features such as views, stored procedures,
+            triggers, <literal>INFORMATION_SCHEMA</literal>, precision
+            math (<literal>DECIMAL</literal> column type), and the
+            <literal>BIT</literal> column type, apply to all storage
+            engines. There are also additions and changes for specific
+            storage engines.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+  <section id="faqs-sql-modes">
+
+    <title>MySQL &current-series; FAQ &mdash; Server SQL Mode</title>
+
+    <qandaset defaultlabel="qanda">
+
+      <qandaentry id="faqs-sql-modes-what">
+
+        <question>
+
+          <para>
+            What are server SQL modes?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Server SQL modes define what SQL syntax MySQL should support
+            and what kind of data validation checks it should perform.
+            This makes it easier to use MySQL in different environments
+            and to use MySQL together with other database servers. The
+            MySQL Server apply these modes individually to different
+            clients. For more information, see
+            <xref
+              linkend="server-sql-mode"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faq-sql-modes-how-many">
+
+        <question>
+
+          <para>
+            How many server SQL modes are there?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Quite a few, as each mode can be individually switched on
+            and off. See <xref linkend="server-sql-mode"/>, for a
+            complete list of available modes.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-sql-modes-determining">
+
+        <question>
+
+          <para>
+            How do you determine the server SQL mode?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            You can set the default SQL mode (for
+            <command>mysqld</command> startup) with the
+            <option>--sql-mode</option> option. Using the statement
+            <literal>SET [SESSION|GLOBAL]
+            sql_mode='<replaceable>modes</replaceable>'</literal>, you
+            can change the settings from within a connection, either
+            locally to the connection, or to take effect globally. You
+            can retrieve the current mode by issuing a <literal>SELECT
+            @@sql_mode</literal> statement.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-sql-modes-scope">
+
+        <question>
+
+          <para>
+            Is the mode dependent on the database or connection?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            A mode is not linked to a particular database. Modes can be
+            set locally to the session (connection), or globally for the
+            server. you can change these settings using <literal>SET
+            [SESSION|GLOBAL]
+            sql_mode='<replaceable>modes</replaceable>'</literal>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-sql-modes-extending">
+
+        <question>
+
+          <para>
+            Can the rules for strict mode be extended?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            When we refer to <emphasis>strict mode</emphasis>, we mean a
+            mode where at least one of the modes
+            <literal>TRADITIONAL</literal>,
+            <literal>STRICT_TRANS_TABLES</literal>, or
+            <literal>STRICT_ALL_TABLES</literal> is enabled. Options can
+            be combined, so you can add additional restrictions to a
+            mode. See <xref linkend="server-sql-mode"/>, for more
+            information.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-sql-modes-performance">
+
+        <question>
+
+          <para>
+            Does strict mode impact performance?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Of course, a setting that requires intensive validation of
+            input data requires some additional time. While the
+            performance impact is not that great, if you do not require
+            such validation (perhaps your application already handles
+            all of this), then MySQL gives you the option of leaving
+            strict mode disabled. However &mdash; if you do require it
+            &mdash; strict mode can provide such validation.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-sql-modes-default">
+
+        <question>
+
+          <para>
+            What is the default server SQL mode when My SQL
+            &current-series; is installed?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            By default, no special modes are enabled. See
+            <xref
+              linkend="server-sql-mode"/>, for
+            information about all available modes and the default
+            behaviour.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+  <section id="faqs-stored-procs">
+
+    <title>MySQL &current-series; FAQ &mdash; Stored
Procedures</title>
+
+    <qandaset defaultlabel="qanda">
+
+      <qandaentry id="faqs-stored-procs-support">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; support stored procedures?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. MySQL &current-series; supports two types of stored
+            routines &mdash; stored procedures and stored functions.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-docs">
+
+        <question>
+
+          <para>
+            Where can I find documentation for MySQL stored procedures
+            and stored functions?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            See <xref linkend="stored-procedures"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-forum">
+
+        <question>
+
+          <para>
+            Is there a discussion forum for MySQL stored procedures?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. See
+            <ulink
+              url="http://forums.mysql.com/list.php?98"
+              >http://forums.mysql.com/list.php?98</ulink>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-spec">
+
+        <question>
+
+          <para>
+            Where can I find the ANSI SQL 2003 specification for stored
+            procedures?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Unfortunately, the official specifications are not freely
+            available (ANSI makes them available for purchase). However,
+            there are books &mdash; such as <citetitle>SQL-99 Complete,
+            Really</citetitle> by Peter Gulutzan and Trudy Pelzer
+            &mdash; which give a comprehensive overview of the standard,
+            including coverage of stored procedures.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-management">
+
+        <question>
+
+          <para>
+            How do you manage stored routines?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            It is always good practice to use a clear naming scheme for
+            your stored routines. You can manage stored procedures with
+            <literal>CREATE [FUNCTION|PROCEDURE]</literal>,
+            <literal>ALTER [FUNCTION|PROCEDURE]</literal>,
<literal>DROP
+            [FUNCTION|PROCEDURE]</literal>, and <literal>SHOW CREATE
+            [FUNCTION|PROCEDURE]</literal>. You can obtain information
+            about existing stored procedures using the
+            <literal>ROUTINES</literal> table in the
+            <literal>INFORMATION_SCHEMA</literal> database (see
+            <xref
+              linkend="routines-table"/>).
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-view-all">
+
+        <question>
+
+          <para>
+            Is there a way to view all stored procedures and stored
+            functions in a given database?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. For a database named <replaceable>dbname</replaceable>,
+            use this query on the
+            <literal>INFORMATION_SCHEMA.ROUTINES</literal> table:
+          </para>
+
+<programlisting>
+SELECT ROUTINE_TYPE, ROUTINE_NAME 
+    FROM INFORMATION_SCHEMA.ROUTINES 
+    WHERE ROUTINE_SCHEMA='<replaceable>dbname</replaceable>';
+</programlisting>
+
+          <para>
+            For more information, see
+            <xref
+              linkend="routines-table"/>.
+          </para>
+
+          <para>
+            The body of a stored routine can be viewed using
+            <literal>SHOW CREATE FUNCTION</literal> (for a stored
+            function) or <literal>SHOW CREATE PROCEDURE</literal> (for a
+            stored procedure). See
+            <xref linkend="show-create-procedure"
+            />, for
+            more information.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-storage">
+
+        <question>
+
+          <para>
+            Where are stored procedures stored?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            In the <literal>proc</literal> table of the
+            <literal>mysql</literal> system database. However, you
+            should not access the tables in the system database
+            directly. Instead, use <literal>SHOW CREATE
+            FUNCTION</literal> to obtain information about stored
+            functions, and <literal>SHOW CREATE PROCEDURE</literal> to
+            obtain information about stored procedures. See
+            <xref
+              linkend="show-create-procedure"/>, for
+            more information about these statements.
+          </para>
+
+          <para>
+            You can also query the <literal>ROUTINES</literal> table in
+            the <literal>INFORMATION_SCHEMA</literal> database &mdash;
+            see <xref linkend="routines-table"/>, for information about
+            this table.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-packages">
+
+        <question>
+
+          <para>
+            Is it possible to group stored procedures or stored
+            functions into packages?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No. This is not supported in MySQL &current-series;.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-call-other-sps">
+
+        <question>
+
+          <para>
+            Can a stored procedure call another stored procedure?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-call-triggers">
+
+        <question>
+
+          <para>
+            Can a stored procedure call a trigger?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            A stored procedure can execute an SQL statement, such as an
+            <literal>UPDATE</literal>, that causes a trigger to fire.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-access-tables">
+
+        <question>
+
+          <para>
+            Can a stored procedure access tables?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. A stored procedure can access one or more tables as
+            required.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-raising-errors">
+
+        <question>
+
+          <para>
+            Do stored procedures have a statement for raising
+            application errors?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Not in MySQL &current-series;. The SQL standard
+            <literal>SIGNAL</literal> and
<literal>RESIGNAL</literal>
+            statements are on the TODO.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-exception-handling">
+
+        <question>
+
+          <para>
+            Do stored procedures provide exception handling?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            MySQL implements <literal>HANDLER</literal> definitions
+            according to the SQL standard. See
+            <xref
+              linkend="declare-handlers"/>, for
+            details.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-return-result-sets">
+
+        <question>
+
+          <para>
+            Can MySQL &current-series; stored routines return result
+            sets?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. If you perform an ordinary <literal>SELECT</literal>
+            inside a stored procedure or stored function, the result set
+            is returned directly to the client. You need to use the
+            MySQL 4.1 client-server protocol for this to work. This
+            means that &mdash; for instance &mdash; in PHP, you need to
+            use the <literal>mysqli</literal> extension rather than the
+            old <literal>mysql</literal> extension.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-with-recompile">
+
+        <question>
+
+          <para>
+            Is
+
+<literallayout>WITH RECOMPILE</literallayout>
+
+            supported for stored procedures?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Not in MySQL &current-series;.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-mod-plsql">
+
+        <question>
+
+          <para>
+            Is there a MySQL equivalent to using
+            <literal>mod_plsql</literal> as a gateway on Apache to talk
+            directly to a stored procedure in the database?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            There is no equivalent in MySQL &current-series;.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-arrays">
+
+        <question>
+
+          <para>
+            Can I pass an array as input to a stored procedure?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Not in MySQL &current-series;.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-cursors-in">
+
+        <question>
+
+          <para>
+            Can I pass a cursor as an <literal>IN</literal> parameter to
+            a stored procedure?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            In MySQL &current-series;, cursors are available inside
+            stored procedures only.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-cursors-out">
+
+        <question>
+
+          <para>
+            Can I return a cursor as an <literal>OUT</literal> parameter
+            from a stored procedure?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            In MySQL &current-series;, cursors are available inside
+            stored procedures only. However, if you do not open a cursor
+            on a <literal>SELECT</literal>, the result will be sent
+            directly to the client. You can also <literal>SELECT
+            INTO</literal> variables. See <xref linkend="select"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-return-value">
+
+        <question>
+
+          <para>
+            Can I print out a variable's value within a stored procedure
+            for debugging purposes?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. If you perform an ordinary <literal>SELECT</literal>
+            inside a stored procedure or stored function, the result set
+            is returned directly to the client. You will need to use the
+            MySQL 4.1 client-server protocol for this to work. This
+            means that &mdash; for instance &mdash; in PHP, you need to
+            use the <literal>mysqli</literal> extension rather than the
+            old <literal>mysql</literal> extension.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-stored-procs-transaction-support">
+
+        <question>
+
+          <para>
+            Can I commit or roll back transactions inside a stored
+            procedure?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. However, you cannot perform transactional operations
+            within a stored function.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+  <section id="faqs-triggers">
+
+    <title>MySQL &current-series; FAQ - Triggers</title>
+
+    <qandaset defaultlabel="qanda">
+
+      <qandaentry id="faqs-triggers-docs">
+
+        <question>
+
+          <para>
+            Where can I find the documentation for MySQL
+            &current-series; triggers?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            See <xref linkend="triggers"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry>
+
+        <question>
+
+          <para>
+            Is there a discussion forum for MySQL Triggers?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. It is available at
+            <ulink
+              url="http://forums.mysql.com/list.php?99"
+              >http://forums.mysql.com/list.php?99</ulink>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-statement-or-row-level">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; have statement-level or
+            row-level triggers?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            In MySQL &current-series;, all triggers are <literal>FOR
+            EACH ROW</literal> &mdash; that is, the trigger is activated
+            for each row that is inserted, updated, or deleted. MySQL
+            &current-series; does not support triggers using
+            <literal>FOR EACH STATEMENT</literal>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-default">
+
+        <question>
+
+          <para>
+            Are there any default triggers?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Not explicitly. MySQL does have specific special behavior
+            for some <literal>TIMESTAMP</literal> columns, as well as
+            for columns which are defined using
+            <literal>AUTO_INCREMENT</literal>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-management">
+
+        <question>
+
+          <para>
+            How are triggers managed in MySQL?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            In MySQL &current-series;, triggers can be created using the
+            <literal>CREATE TRIGGER</literal> statement, and dropped
+            using <literal>DROP TRIGGER</literal>. See
+            <xref
+              linkend="create-trigger"/>, and
+            <xref
+              linkend="drop-trigger"/>, for more about
+            these statements.
+          </para>
+
+          <para>
+            Information about triggers can be obtained by querying the
+            <literal>INFORMATION_SCHEMA.TRIGGERS</literal> table. See
+            <xref linkend="triggers-table"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-view-all">
+
+        <question>
+
+          <para>
+            Is there a way to view all triggers in a given database?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. You can obtain a listing of all triggers defined on
+            database <literal>dbname</literal> using a query on the
+            INFORMATION_SCHEMA.TRIGGERS table such as the one shown
+            here:
+          </para>
+
+<programlisting>
+SELECT TRIGGER_NAME, EVENT_MANIPULATION, EVENT_OBJECT_TABLE, ACTION_STATEMENT 
+    FROM INFORMATION_SCHEMA.TRIGGERS 
+    WHERE TRIGGER_SCHEMA='<replaceable>dbname</replaceable>';
+</programlisting>
+
+          <para>
+            For more information about this table, see
+            <xref
+              linkend="triggers-table"/>.
+          </para>
+
+          <para>
+            You can also use the <literal>SHOW TRIGGERS</literal>
+            statement, which is specific to MySQL. See
+            <xref
+              linkend="show-triggers"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-storage">
+
+        <question>
+
+          <para>
+            Where are triggers stored?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Triggers are currently stored in <filename>.TRG</filename>
+            files, with one such file one per table. In other words, a
+            trigger belongs to a table.
+          </para>
+
+          <para>
+            In the future, we plan to change this so that trigger
+            information will be included in the
+            <filename>.FRM</filename> file that defines the structure of
+            the table. We also plan to make triggers database-level
+            objects &mdash; rather than table-level objects as they are
+            now &mdash; to bring them into compliance with the SQL
+            standard.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-stored-procs">
+
+        <question>
+
+          <para>
+            Can a trigger call a stored procedure?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-table-access">
+
+        <question>
+
+          <para>
+            Can triggers access tables?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            A trigger can access both old and new data in its own table.
+            Through a stored procedure, or a multi-table update or
+            delete statement, a trigger can also affect other tables.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-udfs">
+
+        <question>
+
+          <para>
+            Can triggers call an external application through a UDF?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No, not at present.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-triggers-update-remote-tables">
+
+        <question>
+
+          <para>
+            Is possible for a trigger to update tables on a remote
+            server?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. A table on a remote server could be updated using the
+            <literal>FEDERATED</literal> storage engine. (See
+            <xref
+              linkend="federated-storage-engine"/>).
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+  <section id="faqs-views">
+
+    <title>MySQL &current-series; FAQ &mdash; Views</title>
+
+    <qandaset>
+
+      <qandaentry id="faqs-views-docs">
+
+        <question>
+
+          <para>
+            Where can I find documentation for MySQL Views?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            See <xref linkend="views"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-views-forum">
+
+        <question>
+
+          <para>
+            Is there a discussion forum for MySQL Views?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Yes. See
+            <ulink
+              url="http://forums.mysql.com/list.php?100"
+              >http://forums.mysql.com/list.php?100</ulink>
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-views-alter-underlying-table">
+
+        <question>
+
+          <para>
+            What happens to a view if an underlying table is dropped or
+            renamed?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            After a view has been created, it is possible to drop or
+            alter a table or view to which the definition refers. To
+            check a view definition for problems of this kind, use the
+            <literal>CHECK TABLE</literal> statement. (See
+            <xref
+              linkend="check-table"/>.)
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry>
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; have table snapshots?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-views-materialized">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; have materialized views?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-views-insert-based-joins">
+
+        <question>
+
+          <para>
+            Can you insert into views that are based on joins?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            It is possible, provided that your <literal>INSERT</literal>
+            statement has a column list that makes it clear there's only
+            one table involved.
+          </para>
+
+          <para>
+            You <emphasis>cannot</emphasis> insert into multiple tables
+            with a single insert on a view.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+  <section id="faqs-information-schema">
+
+    <title>MySQL 5.0 FAQ &mdash;
<literal>INFORMATION_SCHEMA</literal></title>
+
+    <qandaset>
+
+      <qandaentry id="faqs-information-schema-docs">
+
+        <question>
+
+          <para>
+            Where can I find documentation for the MySQL
+            <literal>INFORMATION_SCHEMA</literal> database?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            See <xref linkend="information-schema"/>
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-information-schema-forum">
+
+        <question>
+
+          <para>
+            Is there a discussion forum for
+            <literal>INFORMATION_SCHEMA</literal>?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            See
+            <ulink url="http://forums.mysql.com/list.php?101"
+              >http://forums.mysql.com/list.php?101</ulink>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-information-schema-spec">
+
+        <question>
+
+          <para>
+            Where can I find the ANSI SQL 2003 specification for
+            <literal>INFORMATION_SCHEMA</literal>?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Unfortunately, the official specifications are not freely
+            available. (ANSI makes them available for purchase.)
+            However, there are books available &mdash; such as
+            <citetitle>SQL-99 Complete, Really</citetitle> by Peter
+            Gulutzan and Trudy Pelzer &mdash; which give a comprehensive
+            overview of the standard, including
+            <literal>INFORMATION_SCHEMA</literal>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-information-schema-data-dictionary">
+
+        <question>
+
+          <para>
+            What is the difference between the Oracle Data Dictionary
+            and MySQL's <literal>INFORMATION_SCHEMA</literal>?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Both Oracle and MySQL provide metadata in tables. However,
+            Oracle and MySQL use different table names and column names.
+            MySQL's implementation is more similar to those found in DB2
+            and SQL Server, which also support
+            <literal>INFORMATION_SCHEMA</literal> as defined in the SQL
+            standard.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-information-schema-modify-tables">
+
+        <question>
+
+          <para>
+            Can I add to or otherwise modify the tables found in the
+            <literal>INFORMATION_SCHEMA</literal> database?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No. Since applications may rely on a certain standard
+            structure, this should not be modified.For this reason,
+            <emphasis>MySQL AB cannot support bugs or other issues which
+            result from modifying <literal>INFORMATION_SCHEMA</literal>
+            tables or data</emphasis>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+  <section id="faqs-migration">
+
+    <title>MySQL &current-series; FAQ &mdash; Migration</title>
+
+    <qandaset>
+
+      <qandaentry id="faqs-migration-docs">
+
+        <question>
+
+          <para>
+            Where can I find information on how to migrate from MySQL
+            &previous-series; to MySQL &current-series;?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            For detailed upgrade information, see
+            <xref linkend="upgrade"/>. We recommend that you do not skip
+            a major version when upgrading, but rather complete the
+            process in steps, upgrading from one major version to the
+            next in each step. This may seem more complicated, but it
+            will you save time and trouble &mdash; if you encounter
+            problems during the upgrade, their origin will be easier to
+            identify, either by you or &mdash; if you have a MySQL
+            Network subscription &mdash; by MySQL support.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faqs-migration-storage-engines">
+
+        <question>
+
+          <para>
+            How has storage engine (table type) support changed in MySQL
+            &current-series; from previous versions?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Storage engine support has changed as follows:
+
+            <itemizedlist>
+
+              <listitem>
+                <para>
+                  Support for <literal>ISAM</literal> tables was removed
+                  in MySQL 5.0 and you should now use the
+                  <literal>MyISAM</literal> storage engine in place of
+                  <literal>ISAM</literal>. To convert a table
+                  <replaceable>tblname</replaceable> from
+                  <literal>ISAM</literal> to
<literal>MyISAM</literal>,
+                  simply issue a statement such as this one:
+                </para>
+
+<programlisting>ALTER TABLE <replaceable>tblname</replaceable>
ENGINE=MYISAM;</programlisting>
+              </listitem>
+
+              <listitem>
+                <para>
+                  Internal <literal>RAID</literal> for
+                  <literal>MyISAM</literal> tables was also removed in
+                  MySQL 5.0. This was formerly used to allow large
+                  tables in filesystems that did not support filesizes
+                  greater than 2GB. All modern filesystems allow for
+                  larger tables; in addition, there are now other
+                  solutions such as <literal>MERGE</literal> tables and
+                  views.
+                </para>
+              </listitem>
+
+              <listitem>
+                <para>
+                  The <literal>VARCHAR</literal> column type now retains
+                  trailing spaces in all storage engines.
+                </para>
+              </listitem>
+
+              <listitem>
+                <para>
+                  <literal>MEMORY</literal> tables (formerly known as
+                  <literal>HEAP</literal> tables) can also contain
+                  <literal>VARCHAR</literal> columns.
+                </para>
+              </listitem>
+
+            </itemizedlist>
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+  <section id="faq-security">
+
+    <title>MySQL &current-series; FAQ - Security</title>
+
+    <qandaset>
+
+      <qandaentry id="faq-security-ssl-support">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; have native support for SSL?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Most &current-series; binaries have support for SSL
+            connections between the client and server. We can't
+            currently build with the new YaSSL library everywhere, as
+            it's still quite new and does not compile on all platforms
+            yet. See <xref linkend="secure-connections"/>.
+          </para>
+
+          <para>
+            You can also tunnel a connection via SSH, if (for instance)
+            if the client application doesn't support SSL connections.
+            For an example, see <xref linkend="windows-and-ssh"/>.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faq-security-built-in-ssl">
+
+        <question>
+
+          <para>
+            Is SSL support be built into MySQL binaries, or must I
+            recompile the binary myself to enable it?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            Most &current-series; binaries have SSL enabled for
+            client-server connections thsat are secured, authenticated,
+            or both. However, the YaSSL library currently does not
+            compile on all platforms. See
+            <xref linkend="secure-connections"/>, for a complete listing
+            of supported and unsupported platforms.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faq-security-ldap">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; have built-in authentication
+            against LDAP directories?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No. Support for external authentication methods is on the
+            MySQL roadmap as a <quote>rolling feature</quote>, which
+            means that we plan to implement it in the future, but we
+            have not yet determined when this will be done.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+      <qandaentry id="faq-security-roles">
+
+        <question>
+
+          <para>
+            Does MySQL &current-series; include support for Roles Based
+            Access Control (RBAC)?
+          </para>
+
+        </question>
+
+        <answer>
+
+          <para>
+            No. Support for roles is on the MySQL roadmap as a
+            <quote>rolling feature</quote>, which means that we plan to
+            implement it in the future, but we have not yet determined
+            when this will be done.
+          </para>
+
+        </answer>
+
+      </qandaentry>
+
+    </qandaset>
+
+  </section>
+
+</chapter>


Thread
svn commit - mysqldoc@docsrva: r3693 - trunk/refman-5.0jon21 Oct