漁人碼頭

          天行健,君子以自強不息。地勢坤,君子以厚德載物。
          posts - 12, comments - 16, trackbacks - 0, articles - 43
            BlogJava :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理

          MySQL 的engine類型

          Posted on 2007-01-10 12:12 Fisher 閱讀(1793) 評論(0)  編輯  收藏 所屬分類: DataBase
          最開始用MySQL Administrator建數據庫的時候,表缺省是InnoDB類型,也就沒有在意。后來用Access2MySQL導數據的時候發現只能導成MyISAM類型的表,不知道這兩種類型有什么區別,就去查了查。原來是MyISAM類型不支持事務處理等高級處理,而InnoDB類型支持。MyISAM類型的表強調的是性能,其執行數度比InnoDB類型更快,但是不提供事務支持,而InnoDB提供事務支持已經外部鍵等高級數據庫功能。這樣就可以根據數據表不同的用處是用不同的存儲類型。

          另外,MyISAM類型的二進制數據文件可以在不同操作系統中遷移。也就是可以直接從Windows系統拷貝到linux系統中使用。

          從MySQL的官方網站,參考手冊中可以了解到在MySQL4.1中所支持的如下類型:

          Storage Engines and Table Types MySQL supports several storage engines that act as handlers for different table types. MySQL storage engines include both those that handle transaction-safe tables and those that handle non-transaction-safe tables:

          The original storage engine was ISAM, which managed non-transactional tables. This engine has been replaced by MyISAM and should no longer be used. It is deprecated in MySQL 4.1, and is removed in subsequent MySQL release series.

          In MySQL 3.23.0, the MyISAM and HEAP storage engines were introduced. MyISAM is an improved replacement for ISAM. The HEAP storage engine provides in-memory tables. The MERGE storage engine was added in MySQL 3.23.25. It allows a collection of identical MyISAM tables to be handled as a single table. All three of these storage engines handle non-transactional tables, and all are included in MySQL by default. Note that the HEAP storage engine has been renamed the MEMORY engine.

          The InnoDB and BDB storage engines that handle transaction-safe tables were introduced in later versions of MySQL 3.23. Both are available in source distributions as of MySQL 3.23.34a. BDB is included in MySQL-Max binary distributions on those operating systems that support it. InnoDB also is included in MySQL-Max binary distributions for MySQL 3.23. Beginning with MySQL 4.0, InnoDB is included by default in all MySQL binary distributions. In source distributions, you can enable or disable either engine by configuring MySQL as you like.

          The EXAMPLE storage engine was added in MySQL 4.1.3. It is a “stub” engine that does nothing. You can create tables with this engine, but no data can be stored in them or retrieved from them. The purpose of this engine is to serve as an example in the MySQL source code that illustrates how to begin writing new storage engines. As such, it is primarily of interest to developers.

          NDB Cluster is the storage engine used by MySQL Cluster to implement tables that are partitioned over many computers. It is available in source code distributions as of MySQL 4.1.2 and binary distributions as of MySQL-Max 4.1.3.

          The ARCHIVE storage engine was added in MySQL 4.1.3. It is used for storing large amounts of data without indexes in a very small footprint.

          The CSV storage engine was added in MySQL 4.1.4. This engine stores data in text files using comma-separated values format.

          The BLACKHOLE storage engine was added in MySQL 4.1.11. This engine accepts but does not store data and retrievals always return an empty set.

          主站蜘蛛池模板: 江阴市| 扎鲁特旗| 济南市| 文登市| 阿坝县| 阳春市| 靖安县| 夹江县| 曲松县| 高台县| 合江县| 名山县| 青冈县| 孟连| 蓝田县| 阿坝县| 繁昌县| 纳雍县| 禹城市| 贵南县| 临邑县| 那曲县| 舒城县| 定安县| 手游| 依安县| 绥中县| 民权县| 周口市| 普格县| 民勤县| 三河市| 尚志市| 长春市| 阳城县| 耿马| 犍为县| 安阳县| 东乌珠穆沁旗| 太仓市| 巨鹿县|