CSV, ARCHIVE, FEDERATED and EXAMPLE in MySQL 5

CSV, ARCHIVE, FEDERATED and EXAMPLE in MySQL 5

How do the storage engines CSV, ARCHIVE, FEDERATED and EXAMPLE in MySQL 5 change functionality, compared to earlier versions?

    Requires Free Membership to View

    When you register, my team of editors will also send you resources covering Linux administration and management; integration and interoperability between Linux, Windows and Unix; securing Linux and mixed-platform environments; and migrating to Linux.

    Margie Semilof, Editorial Director

    By submitting your registration information to SearchEnterpriseLinux.com you agree to receive email communications from TechTarget and TechTarget partners. We encourage you to read our Privacy Policy which contains important disclosures about how we collect and use your registration and other information. If you reside outside of the United States, by submitting this registration information you consent to having your personal data transferred to and processed in the United States. Your use of SearchEnterpriseLinux.com is governed by our Terms of Use. You may contact us at webmaster@TechTarget.com.

MySQL's pluggable storage engines have generated a lot of excitement recently. A wide variety of storage engines are coming out, each designed to meet some particular aspect of storage requirements.

The CSV engine allows MySQL to access comma separated value files directly. The same file can be read and edited with a spreadsheet program, like Excel, or a text editor, without having to port back and forth between file formats.

The ARCHIVE engine is designed to store large amounts of data in a small space. The rows are compressed (using zlib) as they are inserted, and are decompressed on select. ARCHIVE is a good choice for storing log files.

FEDERATED allows one server to treat another server's tables as if they were local. That means you can write statements with JOIN or UNION between tables stored on separate servers, and you can use 5.0 syntax (including views, stored procedures, the information_schema) with tables stored on an older server. Be careful when doing so, however -- in some circumstances, the remote server must send the entire table over the network to complete the join.

EXAMPLE is a basic skeleton, intended to provide a starting point for writing your own storage engine. Some recent engines stemming from EXAMPLE include an HTTP engine, that allows maps SELECT and INSERT to HTTP GET and PUT requests, and a file storage engine, much like the CSV engine but able handle a variety of field delimiters.

This was first published in May 2007