📄 1834.html
字号:
<TD background="images/bgline.gif" tppabs="http://www.linuxhero.com/docs/images/bgline.gif"><IMG height=22
src="images/header_r2_c1.gif" tppabs="http://www.linuxhero.com/docs/images/header_r2_c1.gif" width=296 border=0
name=header_r2_c1></TD>
<TD background="images/bgline.gif" tppabs="http://www.linuxhero.com/docs/images/bgline.gif" colSpan=5>
<DIV align=right><FONT class=normalfont>当前位置:
<A href="index.html" tppabs="http://www.linuxhero.com/docs/index.html">本站首页</A>
<font color="#FF6699">>></font>
<A href="type30.html" tppabs="http://www.linuxhero.com/docs/type30.html">mysql</A> | <A href="copyright.html" tppabs="http://www.linuxhero.com/docs/copyright.html">版权说明</A></font></DIV>
</TD>
<TD><IMG height=22 src="images/spacer.gif" tppabs="http://www.linuxhero.com/docs/images/spacer.gif" width=1
border=0></TD></TR></TBODY></TABLE>
<TABLE cellSpacing=10 cellPadding=0 width="100%" bgColor=#ffffff
border=0>
<TR>
<TD>
<TABLE cellSpacing=0 cellPadding=3 width="100%" border=0>
<TR>
<TD vAlign=top align=middle width="60%">
<TABLE cellSpacing=0 cellPadding=0 width="100%"
background="images/back.gif" tppabs="http://www.linuxhero.com/docs/images/back.gif" border=0>
<TBODY>
<TR>
<TD vAlign=top width="80%">
<DIV align=center>
<FORM action="search.html" tppabs="http://www.linuxhero.com/docs/search.html" method=get>
</FORM>
<TABLE cellSpacing=0 cellPadding=0 width="95%"
border=0><TBODY>
<TR>
<TD background="images/bgi.gif" tppabs="http://www.linuxhero.com/docs/images/bgi.gif"
height=30></TD></TR></TBODY></TABLE>
<TABLE cellSpacing=0 cellPadding=3 width="95%"
align=center border=0>
<TBODY>
<TR>
<TD>
<TABLE cellSpacing=0 cellPadding=3 width="100%"
border=0>
<TBODY>
<TR>
<TD vAlign=top>
<p><FONT class=normalfont><B><font color=blue>mysql简介</font></B></FONT><BR><FONT class=smallfont color=#ff9900>2004-04-23 15:18 pm</FONT><BR><FONT class=normalfont>作者:作者<br>来自:Linux知识宝库<br>联系方式:无名<br><br> mysql是一个广受Linux社区人们喜爱的半商业的数据库。mysql是可运行在大多数的<br>
Linux平台(i386,Sparc,etc),以及少许非Linux甚至非Unix平台。<br>
<br>
1、 许可费用 <br>
mysql的普及很大程度上源于它的宽松,除了略显不寻常的许可费用。mysql的价格随平<br>
台和安装方式变化。mysql的Windows版本(NT和9X)在任何情况下都不免费,而任何Unix变<br>
种(包括Linux)的mysql如果由用户自己或系统管理员而不是第三方安装则是免费的,第三<br>
方案庄则必须付许可费。<br>
<br>
2、 价格<br>
平台 安装方式 价格 <br>
Windows NT,9X 任何 200美元 <br>
Unix或Linux 自行安装 免费 <br>
Unix或Linux 第三方安装 200美元 <br>
需要一个应用组件 200美元 <br>
可以得到多种支持合同,内容太多不再罗列,最新报价可咨询mysql站点。<br>
<br>
3、 安装<br>
可以在mysql站点上获得大多数主要的软件包格式(RPM、DBE、TGZ),客户端库和各种<br>
语言“包装”(Wrapper)可以分开的RPM格式获得。RPM格式的安装没有多大麻烦, 并且无需<br>
初始配置。在rc3.d(以RedHat RPM为例)生成一个初始脚本,故mysql守护进程在多用户模<br>
式下重启时被启动运行。mysql的守护进程(mysqld)消耗很少的内存(在运行RedHat 5.1<br>
的奔腾133上,每个守护进程使用500K内存和另外4M共享内存的开销)并在只有在执行真正<br>
的查询时才装载到处理器上,这意味着对小型数据库来说,mysql可以相当轻松地使用而不<br>
会对其他系统功能有太大的影响。<br>
<br>
4、 数据类型<br>
字段支持大量数据类型是件好事。通常的整数、浮点数、字符串和数字均以多种长度表<br>
示,并支持变长的BLOB(Binary Large OBject)类型。对整数字段由自动增量选项, 日期<br>
时间字段也能很好的表示。<br>
mysql与大多数其他数据库系统不同的是提供两个相对不常用的字段类型:ENUM和SET。<br>
ENUM是一个枚举类型,非常类适于Pascal语言的枚举类型,它允许程序员看到类似于'red、<br>
'green'、'blue'的字段值,而mysql只将这些值存储为一个字节。SET也是从Pascal借用的,<br>
它也是一个枚举类型,但一个单独字段一次可存储多个值, 这种存储多个枚举值的能力也<br>
许不会给你一些印象(并可能威胁第三范式定义),但正确使用SET和CONTAINS关键字可以<br>
省去很多表连接,能获得很好的性能提高。<br>
<br>
5、 SQL兼容性<br>
mysql包含一些与SQL标准不同的转变, 他们的大多数被设计成是对SQL语言脚本语言的<br>
不足的一种补偿。然而,另一些扩展确实使mysql与众不同,例如,LINK子句搜索是自动地忽<br>
略大小写的。mysql 也允许用户自定义的SQL函数,换句话说, 一个程序员可以编写一个函<br>
数然后集成到mysql中,并且其表现的与任何基本函数如SUM()或AVG()没有什么不同。 函数<br>
必须被编译道一个共享库文件中(.so文件),然后用一个LOAD FUNCTION命令装载。<br>
它也缺乏一些常用的SQL功能,没有子选择(在查询中的查询)。视图(View)也没了。 当<br>
然大多数子查询可以用简单的连接(join)子句重写,但有时用两个嵌套的查询思考问题比一<br>
个大连接容易。同样,视图仅仅为程序员隐蔽where子句, 但这正是程序员们期望的另一种<br>
便利。<br>
<br>
6、 存储过程和触发器<br>
mysql没有一种存储过程(Stored Procedure)语言, 这是对习惯于企业级数据库的程序<br>
员的最大限制。多语句SQL命令必须通过客户方代码来协调, 这种情形是借助于相当健全的<br>
查询语言和赋予客户端锁定和解锁表的能力,这样才允许的多语句运行。<br>
<br>
7、 参考完整性(Referential Integrity-RI)<br>
mysql的主要的缺陷之一是缺乏标准的RI机制;然而,mysql的创造者也不是对其用户的<br>
愿望置若罔闻,并且提供了一些解决办法。其中之一是支持唯一索引。 Rule限制的缺乏(在<br>
给钉字段域上的一种固定的范围限制)通过大量的数据类型来补偿。 不简单地提供检查约束<br>
(一个字段相对于同一行的另一个字段的之值的限制)、 外部关键字和经常与RI相关的“级联<br>
删除”功能。有趣的是,当不支持这些功能时,SQL分析器容忍这些语句的句法。这样做目的<br>
是易于移植数据库到mysql中。这是一个很好的尝试, 并且它确实未来支持该功能留下方便<br>
之门;然而,那些没有仔细阅读文档的的人可能误以为这些功能实际上是存在的。<br>
<br>
8、 安全性<br>
自始至终我对mysql最大的抱怨是其安全系统,它唯一的缺点是复杂而非标准, 另外只<br>
有到调用mysqladmin来重读用户权限时才发生改变。 通常的SQL GRANT/REVOKE 语句到最近<br>
的版本才被支持,但是至少他们现在有了。 mysql的编写者广泛地记载了其特定的安全性系<br>
统,但是它确实需要一条可能是别无它法的学习过程。<br>
<br>
9、备份和恢复、数据导入/导出<br>
强制参考一致性的缺乏显著地简化备份和恢复, 单靠数据导入/导出就可完美复制这一<br>
功能。LOAD DATA INFILE命令给了数据导入很大的灵活性。 SELECT INTO命令实现了数据导<br>
出的相等功能。另外,既然mysql不使用原始的分区, 所有的数据库数据能用一个文件系统<br>
备份保存。数据库活动能被记载。 与通常的数据库日志不同(存储记录变化或在记录映像之<br>
前/之后), mysql记载实际的SQL语句。这允许数据库被恢复到失败前的那一点,但是不允许<br>
提交(commit)和回卷(rollback)操作。<br>
<br>
<br>
10、连接性<br>
mysql客户库是客户/服务器结构的C语言库, 它意味着一个客户能查询驻留在另一台机<br>
器的一个数据库。然而mysql真正的强项处于该库中的语言“包装器(wrapper)”, Perl、<br>
Pathon和PHP只是一部分。Apache的Web服务器也有许多模块例如目录存取文件等允许各种各<br>
样的Apache配置信息(例如目录存取文件)使用mysql,应用程序接口简单、 一致并且相但完<br>
整。另外、多平台ODBC驱动程序可自由获得。<br>
<br>
11、未来<br>
mysql的开发继续以快速进行着。事实上,开发步伐对大多数开放源代码是一种挑战。<br>
本文提到的几个抱怨中有很多新功能正在解决,然而,我将不对还没确实存在的特征做评价。<br>
开发者们向我表明了在未来的开发中把增加查询功能和提高查询速度作为最高优先级。<br>
<br>
11、总结<br>
mysql是数据库领域的中间派。它缺乏一个全功能数据库的大多数主要特征, 但是又有<br>
比类似Xbase记录存储引擎更多的特征。它象企业级RDBMS那样需要一个积极的服务者守护程<br>
序,但是不能象他们那样消费资源。查询语言允许复杂的连接(join)查询,但是所有的参考<br>
完整必须由程序员强制保证。<br>
mysql在Linux世界里找到一个位置-提供简洁和速度,同时仍然提供足够的功能使程序<br>
员高兴。数据库程序员将喜欢其查询功能和广泛的客户库,数据库管理员会觉得系统缺乏主<br>
要数据库功能,他们会发觉它对简单数据库(在不能保证购买大牌数据库时)是有价值的。<br>
</FONT><br>
</TD>
</TR>
<TR>
<TD colSpan=2><FONT
class=middlefont></FONT><BR>
<FONT
class=normalfont>全文结束</FONT> </TD>
</TR>
<TR>
<TD background="images/dot.gif" tppabs="http://www.linuxhero.com/docs/images/dot.gif" colSpan=2
height=10></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></DIV></TD>
<TD vAlign=top width="20%"
background="images/line.gif" tppabs="http://www.linuxhero.com/docs/images/line.gif" rowSpan=2>
<DIV align=center>
<table class=tableoutline cellspacing=1 cellpadding=4
width="100%" align=center border=0>
<tr class=firstalt>
<td noWrap background="images/bgline.gif" tppabs="http://www.linuxhero.com/docs/images/bgline.gif" colspan=2 height=21>
<font class=normalfont><b>所有分类</b></font></td>
</tr>
<tr class=secondalt> <td noWrap width=27%> <font class=normalfont>1:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type1.html" tppabs="http://www.linuxhero.com/docs/type1.html">非技术类</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>2:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type2.html" tppabs="http://www.linuxhero.com/docs/type2.html">基础知识</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>3:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type3.html" tppabs="http://www.linuxhero.com/docs/type3.html">指令大全</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>4:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type4.html" tppabs="http://www.linuxhero.com/docs/type4.html">shell</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>5:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type5.html" tppabs="http://www.linuxhero.com/docs/type5.html">安装启动</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>6:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type6.html" tppabs="http://www.linuxhero.com/docs/type6.html">xwindow</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>7:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type7.html" tppabs="http://www.linuxhero.com/docs/type7.html">kde</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>8:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type8.html" tppabs="http://www.linuxhero.com/docs/type8.html">gnome</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>9:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type9.html" tppabs="http://www.linuxhero.com/docs/type9.html">输入法类</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>10:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type10.html" tppabs="http://www.linuxhero.com/docs/type10.html">美化汉化</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>11:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type11.html" tppabs="http://www.linuxhero.com/docs/type11.html">网络配置</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>12:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type12.html" tppabs="http://www.linuxhero.com/docs/type12.html">存储备份</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>13:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type13.html" tppabs="http://www.linuxhero.com/docs/type13.html">杂项工具</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>14:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type14.html" tppabs="http://www.linuxhero.com/docs/type14.html">编程技术</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>15:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type15.html" tppabs="http://www.linuxhero.com/docs/type15.html">网络安全</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>16:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type16.html" tppabs="http://www.linuxhero.com/docs/type16.html">内核技术</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>17:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type17.html" tppabs="http://www.linuxhero.com/docs/type17.html">速度优化</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>18:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type18.html" tppabs="http://www.linuxhero.com/docs/type18.html">apache</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>19:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type19.html" tppabs="http://www.linuxhero.com/docs/type19.html">email</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>20:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type20.html" tppabs="http://www.linuxhero.com/docs/type20.html">ftp服务</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>21:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type21.html" tppabs="http://www.linuxhero.com/docs/type21.html">cvs服务</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>22:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type22.html" tppabs="http://www.linuxhero.com/docs/type22.html">代理服务</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>23:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type23.html" tppabs="http://www.linuxhero.com/docs/type23.html">samba</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>24:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type24.html" tppabs="http://www.linuxhero.com/docs/type24.html">域名服务</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>25:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type25.html" tppabs="http://www.linuxhero.com/docs/type25.html">网络过滤</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>26:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type26.html" tppabs="http://www.linuxhero.com/docs/type26.html">其他服务</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>27:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type27.html" tppabs="http://www.linuxhero.com/docs/type27.html">nfs</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>28:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type28.html" tppabs="http://www.linuxhero.com/docs/type28.html">oracle</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>29:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type29.html" tppabs="http://www.linuxhero.com/docs/type29.html">dhcp</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>30:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type30.html" tppabs="http://www.linuxhero.com/docs/type30.html">mysql</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>31:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type31.html" tppabs="http://www.linuxhero.com/docs/type31.html">php</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>32:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type32.html" tppabs="http://www.linuxhero.com/docs/type32.html">ldap</a></font></td> </tr> </table></td></tr> </table>
</DIV></TD></TR>
<TR vAlign=top>
<TD width="80%">
<DIV align=center><BR>
</DIV>
</TD></TR></TBODY></TABLE></TD></TR>
</TABLE></TD></TR>
</TABLE>
<TABLE cellSpacing=0 cellPadding=4 width="100%" bgColor=#eeeeee
border=0><TBODY>
<TR>
<TD width="50%">
<P><FONT class=middlefont>版权所有 © 2004 <A
href="mailto:bjchenxu@sina.com">linux知识宝库</A><BR>
违者必究. </FONT></P>
</TD>
<TD width="50%">
<DIV align=right><FONT class=middlefont>Powered by: <A
href="mailto:bjchenxu@sina.com">Linux知识宝库</A> Version 0.9.0 </FONT></DIV>
</TD></TR></TBODY></TABLE>
<CENTER></CENTER></TD></TR>
</TABLE></CENTER></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -