cvs: phpdoc-zh /reference/mysql/functions mysql-drop-db.xml mysql-errno.xml mysql-error.xml
| From: | Dallas Thunder | Date: | Tue, 25 Feb 2003 10:29:06 +0000 |
| Subject: | cvs: phpdoc-zh /reference/mysql/functions mysql-drop-db.xml mysql-errno.xml mysql-error.xml | ||
| Groups: | php.doc.zh | ||
| Request: | Send a blank email to doc-zh+get-1138@lists.php.net to get a copy of this message | ||
dallas Tue Feb 25 05:29:06 2003 EDT
Added files:
/phpdoc-zh/reference/mysql/functions mysql-drop-db.xml
mysql-errno.xml
mysql-error.xml
Log:
Complete 1.5 1.5 1.6
Index: phpdoc-zh/reference/mysql/functions/mysql-drop-db.xml
+++ phpdoc-zh/reference/mysql/functions/mysql-drop-db.xml
<?xml version="1.0" encoding="gb2312"?>
<!-- $Revision: 1.1 $ -->
<!-- $Author: dallas $ -->
<!-- EN-Revision: 1.5 Maintainer: dallas Status: ready -->
<refentry id="function.mysql-drop-db">
<refnamediv>
<refname>mysql_drop_db</refname>
<refpurpose>¶ªÆú£¨É¾³ý£©Ò»¸ö MySQL Êý¾Ý¿â</refpurpose>
</refnamediv>
<refsect1>
<title>˵Ã÷</title>
<methodsynopsis>
<type>bool</type><methodname>mysql_drop_db</methodname>
<methodparam><type>string</type><parameter>database_name</parameter></methodparam>
<methodparam choice="opt"><type>resource</type><parameter>
link_identifier
</parameter></methodparam>
</methodsynopsis>
<para>
&return.success;
</para>
<para>
<function>mysql_drop_db</function>
³¢ÊÔ¶ªÆú£¨É¾³ý£©Ö¸¶¨Á¬½Ó±êʶËù¹ØÁªµÄ·þÎñÆ÷ÉϵÄÒ»Õû¸öÊý¾Ý¿â¡£
</para>
<para>
ΪÏòϼæÈÝÒ²¿ÉÒÔÓÃ
<function>mysql_dropdb</function>¡£µ«²¢²»Ìᳫ¡£
</para>
<note>
<para>
²»ÌᳫʹÓà <function>mysql_drop_db</function> º¯Êý¡£×îºÃÓÃ
<function>mysql_query</function> Ìá½»Ò»Ìõ
SQL DROP DATABASE Óï¾äÀ´Ìæ´ú¡£
</para>
</note>
<para>
²Î¼û <function>mysql_create_db</function> ºÍ
<function>mysql_query</function>¡£
</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"../../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->
Index: phpdoc-zh/reference/mysql/functions/mysql-errno.xml
+++ phpdoc-zh/reference/mysql/functions/mysql-errno.xml
<?xml version="1.0" encoding="gb2312"?>
<!-- $Revision: 1.1 $ -->
<!-- $Author: dallas $ -->
<!-- EN-Revision: 1.5 Maintainer: dallas Status: ready -->
<refentry id="function.mysql-errno">
<refnamediv>
<refname>mysql_errno</refname>
<refpurpose>
·µ»ØÉÏÒ»¸ö MySQL ²Ù×÷ÖеĴíÎóÐÅÏ¢µÄÊý×Ö±àÂë
</refpurpose>
</refnamediv>
<refsect1>
<title>˵Ã÷</title>
<methodsynopsis>
<type>int</type><methodname>mysql_errno</methodname>
<methodparam choice="opt"><type>resource</type><parameter>
link_identifier
</parameter></methodparam>
</methodsynopsis>
<para>
·µ»ØÉÏÒ»¸ö MySQL º¯ÊýµÄ´íÎóºÅÂ룬Èç¹ûûÓгö´íÔò·µ»Ø
<literal>0</literal>£¨Á㣩¡£
</para>
<para>
´Ó MySQL Êý¾Ý¿âºó¶ËÀ´µÄ´íÎó²»ÔÙ·¢³ö¾¯¸æ£¬ÒªÓÃ
<function>mysql_errno</function>
À´ÌáÈ¡´íÎó´úÂë¡£×¢Òâ±¾º¯Êý½ö·µ»Ø×î½üÒ»´Î
MySQL º¯ÊýµÄÖ´ÐУ¨²»°üÀ¨ <function>mysql_error</function> ºÍ
<function>mysql_errno</function>£©µÄ´íÎó´úÂ룬Òò´ËÈç¹ûҪʹÓô˺¯Êý£¬È·±£ÔÚµ÷ÓÃÁíÒ»¸ö
MySQL º¯Êý֮ǰ¼ì²éËüµÄÖµ¡£
<example>
<title>mysql_errno Àý×Ó</title>
<programlisting role="php">
<![CDATA[
<?php
mysql_connect("localhost", "mysql_user", "mysql_password");
mysql_select_db("nonexistentdb");
echo mysql_errno() . ": " . mysql_error(). "\n";
mysql_select_db("kossu");
mysql_query("SELECT * FROM nonexistenttable");
echo mysql_errno() . ": " . mysql_error() . "\n";
?>
]]>
</programlisting>
<para>
ÒÔÉÏÀý×Ó½«²úÉúÈçÏÂÊä³ö£º
</para>
<screen>
<![CDATA[
1049: Unknown database 'nonexistentdb'
1146: Table 'kossu.nonexistenttable' doesn't exist
]]>
</screen>
</example>
</para>
<note>
<para>
Èç¹ûÖ¸¶¨ÁË¿ÉÑ¡²ÎÊýÔòÓøø¶¨µÄÁ¬½ÓÌáÈ¡´íÎó´úÂë¡£·ñÔòʹÓÃÉÏÒ»¸ö´ò¿ªµÄÁ¬½Ó¡£
</para>
</note>
<para>
²Î¼û <function>mysql_error</function>¡£
</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"../../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->
Index: phpdoc-zh/reference/mysql/functions/mysql-error.xml
+++ phpdoc-zh/reference/mysql/functions/mysql-error.xml
<?xml version="1.0" encoding="gb2312"?>
<!-- $Revision: 1.1 $ -->
<!-- $Author: dallas $ -->
<!-- EN-Revision: 1.6 Maintainer: dallas Status: ready -->
<refentry id="function.mysql-error">
<refnamediv>
<refname>mysql_error</refname>
<refpurpose>
·µ»ØÉÏÒ»¸ö MySQL ²Ù×÷²úÉúµÄÎı¾´íÎóÐÅÏ¢
</refpurpose>
</refnamediv>
<refsect1>
<title>˵Ã÷</title>
<methodsynopsis>
<type>string</type><methodname>mysql_error</methodname>
<methodparam choice="opt"><type>resource</type><parameter>
link_identifier
</parameter></methodparam>
</methodsynopsis>
<para>
·µ»ØÉÏÒ»¸ö MySQL º¯ÊýµÄ´íÎóÎı¾£¬Èç¹ûûÓгö´íÔò·µ»Ø
<literal>''</literal>£¨¿Õ×Ö·û´®£©¡£
</para>
<para>
´Ó MySQL Êý¾Ý¿âºó¶ËÀ´µÄ´íÎó²»ÔÙ·¢³ö¾¯¸æ£¬ÒªÓÃ
<function>mysql_error</function>
À´ÌáÈ¡´íÎóÎı¾¡£×¢Òâ±¾º¯Êý½ö·µ»Ø×î½üÒ»´Î
MySQL º¯ÊýµÄÖ´ÐУ¨²»°üÀ¨ <function>mysql_error</function> ºÍ
<function>mysql_errno</function>£©µÄ´íÎóÎı¾£¬Òò´ËÈç¹ûҪʹÓô˺¯Êý£¬È·±£ÔÚµ÷ÓÃÁíÒ»¸ö
MySQL º¯Êý֮ǰ¼ì²éËüµÄÖµ¡£
<example>
<title>mysql_error Àý×Ó</title>
<programlisting role="php">
<![CDATA[
<?php
mysql_connect("localhost", "mysql_user", "mysql_password");
mysql_select_db("nonexistentdb");
echo mysql_errno() . ": " . mysql_error(). "\n";
mysql_select_db("kossu");
mysql_query("SELECT * FROM nonexistenttable");
echo mysql_errno() . ": " . mysql_error() . "\n";
?>
]]>
</programlisting>
<para>
ÒÔÉÏÀý×Ó½«²úÉúÈçÏÂÊä³ö£º
</para>
<screen>
<![CDATA[
1049: Unknown database 'nonexistentdb'
1146: Table 'kossu.nonexistenttable' doesn't exist
]]>
</screen>
</example>
</para>
<note>
<para>
Èç¹ûÖ¸¶¨ÁË¿ÉÑ¡²ÎÊýÔòÓøø¶¨µÄÁ¬½ÓÌáÈ¡´íÎó´úÂë¡£·ñÔòʹÓÃÉÏÒ»¸ö´ò¿ªµÄÁ¬½Ó¡£
</para>
</note>
<para>
²Î¼û <function>mysql_errno</function>¡£
</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"../../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->