<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>PlanetMysql.ru - информация о СУБД MySQL &#187; Tables</title>
	<atom:link href="http://planetmysql.ru/category/tables/feed/" rel="self" type="application/rss+xml" />
	<link>http://planetmysql.ru</link>
	<description>Блог о самой популярной СУБД MySQL</description>
	<lastBuildDate>Thu, 24 May 2012 22:24:00 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>What is this MySQL file used for?</title>
		<link>http://www.mysqlfanboy.com/2011/02/what-is-this-mysql-file-used-for/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=what-is-this-mysql-file-used-for</link>
		<comments>http://www.mysqlfanboy.com/2011/02/what-is-this-mysql-file-used-for/#comments</comments>
		<pubDate>Thu, 17 Feb 2011 00:26:06 +0000</pubDate>
		<dc:creator>Mark Grennan</dc:creator>
				<category><![CDATA[CSV]]></category>
		<category><![CDATA[data]]></category>
		<category><![CDATA[files]]></category>
		<category><![CDATA[Index]]></category>
		<category><![CDATA[myisam]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[Table]]></category>
		<category><![CDATA[Tables]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://www.mysqlfanboy.com/?p=516</guid>
		<description><![CDATA[MySQL  keeps many different files, some contain real data, some contain meta  data. Witch ones are important? Witch can your throw away?
This  is my attempt to create a quick reference of all the files used by  MySQL, whats in them, what can you do if they are missing, what can you  do with them.
When I was working for Dell doing Linux support my first words to a customer where “DO YOU HAVE COMPLETE AND VERIFIED BACKUP?” Make one now before you think about doing anything I suggest here.
You should always try to manage your data through a MySQL client.   If things have gone very bad this may not be possible. MySQL may not  start. If your file system get corrupt you may have missing files.  Sometimes people create other files in the MySQL directory (BAD).  This  should help you understand what is safe to remove.

Before you try to work with one of these files make sure you have the file permissions set correctly.
This  may not be a complete list of files used my MySQL.  It most certainly  doesn’t describe everything each table is used for. If you know of ways  to replace a missing file or what happens to MySQL when a file is  missing that I haven’t described here, please leave me a comment or  email me.  I’ll update this document and give your a reference.
my.cnf
This file alters the default configuration settings. MySQL looks in the /etc directory for my.cnf. You should review this file  to insure you are looking in the right place for all other MySQL files.   MySQL WILL run without it.  If you have trouble getting MySQL to  start, read the error log then try moving are renaming this file.
mysql &#60;directory&#62;
On  Linux servers the default location for MySQL files is /var/lib/mysql.   This directory is controlled by the “datadir” variable.
Do I need to say, deleting this directory deletes everything?
ibdata1
If your remove this file your InnoDB DATA IS GONE and MySQL will recreate an empty file.
If  you are not using the innodb_file_per_table option (default), this file  holds almost ALL of your data in InnoDB tables.  This file is all but  useless without its corresponding  ‘.frm’ file for each table in the  right database directory. If all you have is the .frm files you can  recreate the structure of your tables. (See below.)
Idbdata1  can get really big. The default size is 10MB. MySQL will automatically  extended it by the default size as needed. If MySQL crashed, some of  your InnoDB data may be in your transaction logs (ib_logfile.*).
By design the InnoDB file does not shrink. The safest way to shrink this file is to take a complete backup, stop MySQL, remove the ib* files, start MySQL and restore all your data.  REALLY.
DatabaseName &#60;directory in mysql&#62;
Each  MySQL database has a directory named after it.  Each directory holds  the meta data for the database. Your MyISAM data is in this directory.  InnoDB tables may be here if the innodb_file_per_table variable is used.  By default InnoDB tables are in the ibdata1 file (see above).
If  you delete the directory your data may be gone. MyISAM data WILL be  lost.  InnoDB tables may still be in the ibdata1.  If so, you will need  to recreate the meta data files to recover your data.
Creating  a directory is almost equivalent to ‘create database’.  If a directory  exists MySQL will show you have a database by that name. The create  database command may also creates a db.opt file.
&#60;TableName&#62;.frm
This file is key  to both InnoDB and MyISAM databases. It is the meta data to the  location of your data. It contains the table column definitions.
If  you remove this file MySQL will tell you your DATA doesn’t exist.  It  does. Your data is still in the ibdata (.ibd) file or the ibdata1 file.  You need to recreate the table to recreate this file. If you don’t know  the exact structure of this table your out of luck.
Stop  MySQL and move the .MYD and .MYI files to another directory.  (You  might also make a backup copy.) Start MySQL and recreate this table.  Stop MySQL and copy the .MYD and .MYI files back to the database  directory and restart MySQL.
&#60;TableName&#62;.MYD
THIS IS YOUR MyISAM DATA.  If this is all you have, and you know the data structure of the the  table, all is not lost.  (See .frm Above.)  You may also need to  recreate the .MYI index file.
&#60;TableName&#62;.MYI
This  file contains the indexs for your table.  If it becomes corrupt or is  deleted you can recreate it using the ‘REPAIR TABLE table_name USE_FRM;’  command.
&#60;TableName&#62;.ibd
THIS IS YOUR InnoDB DATA. If  this is all you have, and you know the data structure of the the table,  all is not lost.  (See .frm Above.) Unlink MyISAM tables the indexes  are contained in this file with your data.
MySQL doesn’t create this file unless you are using the innodb_file_per_table option.
&#60;TableName&#62;.CSV
THIS IS YOUR CSV DATA.  This file contains comma separated text data. These file do not have indexes.
&#60;TableName&#62;.CSM
This  file contains meta data for CSV and archive tables.  I have not found  what is stored here. I do know it tells MySQL if you are logging to the  general logs.
ib_logfile*
This file contains your un-committed transactions data. MySQL uses it to recover from a crash.
If you shut down InnoDB cleanly, you can remove them. MySQL will recreate them.
If  you change the size of innodb_log_file_size, you will need to recreate  these files by stopping MySQL cleanly and deleting them.
mysql-bin.*
This “Bin Log”  files contain any change made to any database. Each transaction is  assigned a MASTER_LOG_POS(ion).  These files are not created by default.  They are used for replication and point-in-time recovery.
You  can stop the server and remove these files IF you remove the  mysql-bin.index file as well.  MySQL creates a new bin log file each  time it starts or the logs are flushed.  Deleting these files will the  server is running will break replication.
mysql-bin.index
This fail is used by MySQL to keep a Bin Log list.  It is a simple text file like;
./mysql-bin.000001
./mysql-bin.000002
./mysql-bin.000003
If  you remove this file, MySQL will recreate it with only the newest bin  log name. If you need to remove old bin logs use the command “purge binary logs [to mysql-bin.######] [before “yyyy-mm-dd”]”.
You can control the number of bin logs using the expire_logs_days variable.
mysqld.log
This is MySQL’s primary administration log.  MySQL reports starts and stops as well as some warning and errors in  this file.  If MySQL crashes, mysqld_safe will restart it. This log will  report this.
You can delete this file if needed.
slow.log
The slow query log consists of all SQL statements that took more than long_query_time seconds to execute and (as of MySQL 5.1.21) required at least min_examined_row_limit rows to be examined.
You can delete this file if needed.
db.opt
Database  characteristics, like the CHARACTER SET clause are stored in the db.opt  file. You may have strange query results if this file is missing. MySQL  will use it’s default. You can recreate this file my altering the table  with the correct settings.
mysql.pid
The PID file hold the process ID number for the running server. MySQL creates this  file and scripts that start and stop MySQL use it to control MySQL.
MySQL  will remove this file when is stops. You should not delete it if MySQL  is running. If mysql is NOT running and the file exists MySQL may have  crashed and you should delete this file.

References:
FULL DISK
http://dev.mysql.com/doc/refman/5.1/en/full-disk.html
MySQL Database Backup .MYI and .MYD
http://www.aeonity.com/frost/mysql-database-backup-myi-myd
Recovering from Crashes
http://dev.mysql.com/tech-resources/articles/recovering-from-crashes.html
Tweet]]></description>
			<content:encoded><![CDATA[<p>MySQL  keeps many different files, some contain real data, some contain meta  data. Witch ones are important? Witch can your throw away?</p>
<p>This  is my attempt to create a quick reference of all the files used by  MySQL, whats in them, what can you do if they are missing, what can you  do with them.</p>
<p>When I was working for Dell doing Linux support my first words to a customer where “DO YOU HAVE COMPLETE AND VERIFIED BACKUP?” Make one now before you think about doing anything I suggest here.</p>
<p>You should always try to manage your data through a MySQL client.   If things have gone very bad this may not be possible. MySQL may not  start. If your file system get corrupt you may have missing files.  Sometimes people create other files in the MySQL directory (BAD).  This  should help you understand what is safe to remove.</p>
<p><span></span></p>
<p>Before you try to work with one of these files make sure you have the file permissions set correctly.</p>
<p>This  may not be a complete list of files used my MySQL.  It most certainly  doesn’t describe everything each table is used for. If you know of ways  to replace a missing file or what happens to MySQL when a file is  missing that I haven’t described here, please leave me a comment or  email me.  I’ll update this document and give your a reference.</p>
<h3>my.cnf</h3>
<p>This file alters the default configuration settings. MySQL looks in the /etc directory for my.cnf. You should review this file  to insure you are looking in the right place for all other MySQL files.   MySQL WILL run without it.  If you have trouble getting MySQL to  start, read the error log then try moving are renaming this file.</p>
<h3>mysql &lt;directory&gt;</h3>
<p>On  Linux servers the default location for MySQL files is /var/lib/mysql.   This directory is controlled by the “datadir” variable.</p>
<p>Do I need to say, deleting this directory deletes everything?</p>
<h3>ibdata1</h3>
<p>If your remove this file your InnoDB DATA IS GONE and MySQL will recreate an empty file.</p>
<p>If  you are not using the innodb_file_per_table option (default), this file  holds almost ALL of your data in InnoDB tables.  This file is all but  useless without its corresponding  ‘.frm’ file for each table in the  right database directory. If all you have is the .frm files you can  recreate the structure of your tables. (See below.)</p>
<p>Idbdata1  can get really big. The default size is 10MB. MySQL will automatically  extended it by the default size as needed. If MySQL crashed, some of  your InnoDB data may be in your transaction logs (ib_logfile.*).</p>
<p>By design the InnoDB file does not shrink. The <a href="http://vdachev.net/2007/02/22/mysql-reducing-ibdata1/">safest way to shrink</a> this file is to take a complete backup, stop MySQL, remove the ib* files, start MySQL and restore all your data.  REALLY.</p>
<h3>DatabaseName &lt;directory in mysql&gt;</h3>
<p>Each  MySQL database has a directory named after it.  Each directory holds  the meta data for the database. Your MyISAM data is in this directory.  InnoDB tables may be here if the innodb_file_per_table variable is used.  By default InnoDB tables are in the ibdata1 file (see above).</p>
<p>If  you delete the directory your data may be gone. MyISAM data WILL be  lost.  InnoDB tables may still be in the ibdata1.  If so, you will need  to recreate the meta data files to recover your data.</p>
<p>Creating  a directory is almost equivalent to ‘create database’.  If a directory  exists MySQL will show you have a database by that name. The create  database command may also creates a db.opt file.</p>
<h3>&lt;TableName&gt;.frm</h3>
<p>This file is key  to both InnoDB and MyISAM databases. It is the meta data to the  location of your data. It contains the table column definitions.</p>
<p>If  you remove this file MySQL will tell you your DATA doesn’t exist.  It  does. Your data is still in the ibdata (.ibd) file or the ibdata1 file.  You need to recreate the table to recreate this file. If you don’t know  the exact structure of this table your out of luck.</p>
<p>Stop  MySQL and move the .MYD and .MYI files to another directory.  (You  might also make a backup copy.) Start MySQL and recreate this table.  Stop MySQL and copy the .MYD and .MYI files back to the database  directory and restart MySQL.</p>
<h3>&lt;TableName&gt;.MYD</h3>
<p>THIS IS YOUR MyISAM DATA.  If this is all you have, and you know the data structure of the the  table, all is not lost.  (See .frm Above.)  You may also need to  recreate the .MYI index file.</p>
<h3>&lt;TableName&gt;.MYI</h3>
<p>This  file contains the indexs for your table.  If it becomes corrupt or is  deleted you can recreate it using the ‘REPAIR TABLE table_name USE_FRM;’  command.</p>
<h3>&lt;TableName&gt;.ibd</h3>
<p>THIS IS YOUR InnoDB DATA. If  this is all you have, and you know the data structure of the the table,  all is not lost.  (See .frm Above.) Unlink MyISAM tables the indexes  are contained in this file with your data.</p>
<p>MySQL doesn’t create this file unless you are using the innodb_file_per_table option.</p>
<h3>&lt;TableName&gt;.CSV</h3>
<p>THIS IS YOUR CSV DATA.  This file contains comma separated text data. These file do not have indexes.</p>
<h3>&lt;TableName&gt;.CSM</h3>
<p>This  file contains meta data for CSV and archive tables.  I have not found  what is stored here. I do know it tells MySQL if you are logging to the  general logs.</p>
<h3>ib_logfile*</h3>
<p>This file contains your un-committed transactions data. MySQL uses it to recover from a crash.</p>
<p>If you shut down InnoDB cleanly, you can remove them. MySQL will recreate them.</p>
<p>If  you change the size of innodb_log_file_size, you will need to recreate  these files by stopping MySQL cleanly and deleting them.</p>
<h3>mysql-bin.*</h3>
<p>This “<a href="http://forge.mysql.com/wiki/MySQL_Internals_Binary_Log#High-Level_Binary_Log_Structure_and_Contents">Bin Log</a>”  files contain any change made to any database. Each transaction is  assigned a MASTER_LOG_POS(ion).  These files are not created by default.  They are used for <a href="http://dev.mysql.com/doc/refman/5.1/en/replication-howto.html">replication</a> and point-in-time recovery.</p>
<p>You  can stop the server and remove these files IF you remove the  mysql-bin.index file as well.  MySQL creates a new bin log file each  time it starts or the logs are flushed.  Deleting these files will the  server is running will break replication.</p>
<h3>mysql-bin.index</h3>
<p>This fail is used by MySQL to keep a Bin Log list.  It is a simple text file like;</p>
<p>./mysql-bin.000001</p>
<p>./mysql-bin.000002</p>
<p>./mysql-bin.000003</p>
<p>If  you remove this file, MySQL will recreate it with only the newest bin  log name. If you need to remove old bin logs use the command “purge binary logs [to mysql-bin.######] [before “yyyy-mm-dd”]”.</p>
<p>You can control the number of bin logs using the expire_logs_days variable.</p>
<h3>mysqld.log</h3>
<p>This is MySQL’s primary <a href="http://dev.mysql.com/doc/refman/5.1/en/log-file-maintenance.html">administration log</a>.  MySQL reports starts and stops as well as some warning and errors in  this file.  If MySQL crashes, mysqld_safe will restart it. This log will  report this.</p>
<p>You can delete this file if needed.</p>
<h3>slow.log</h3>
<p>The <a href="http://dev.mysql.com/doc/refman/5.1/en/slow-query-log.html">slow query log</a> consists of all SQL statements that took more than<a href="http://dev.mysql.com/doc/refman/5.1/en/server-system-variables.html#sysvar_long_query_time"> long_query_time</a> seconds to execute and (as of MySQL 5.1.21) required at least<a href="http://dev.mysql.com/doc/refman/5.1/en/server-system-variables.html#sysvar_min_examined_row_limit"> min_examined_row_limit</a> rows to be examined.</p>
<p>You can delete this file if needed.</p>
<h3>db.opt</h3>
<p>Database  characteristics, like the CHARACTER SET clause are stored in the db.opt  file. You may have strange query results if this file is missing. MySQL  will use it’s default. You can recreate this file my altering the table  with the correct settings.</p>
<h3>mysql.pid</h3>
<p>The <a href="http://dev.mysql.com/doc/refman/5.1/en/mysql-server.html">PID file</a> hold the process ID number for the running server. MySQL creates this  file and scripts that start and stop MySQL use it to control MySQL.</p>
<p>MySQL  will remove this file when is stops. You should not delete it if MySQL  is running. If mysql is NOT running and the file exists MySQL may have  crashed and you should delete this file.</p>
<p><img class="alignnone" src="http://mark.grennan.com/images/MarkGrennanSigniture.bmp" alt="" width="166" height="69" /></p>
<h6>References:</h6>
<p>FULL DISK<br />
<a href="http://dev.mysql.com/doc/refman/5.1/en/full-disk.html">http://dev.mysql.com/doc/refman/5.1/en/full-disk.html</a></p>
<p>MySQL Database Backup .MYI and .MYD<br />
<a href="http://www.aeonity.com/frost/mysql-database-backup-myi-myd">http://www.aeonity.com/frost/mysql-database-backup-myi-myd</a></p>
<p>Recovering from Crashes<br />
<a href="http://dev.mysql.com/tech-resources/articles/recovering-from-crashes.html">http://dev.mysql.com/tech-resources/articles/recovering-from-crashes.html</a></p>
<p><a href="http://twitter.com/share?url=http://www.mysqlfanboy.com/2011/02/what-is-this-mysql-file-used-for/&amp;count=none&amp;via=MySQLFanBoy&amp;related=MySQLFanBoy:Site+Twitter+account&amp;text=What%20is%20this%20MySQL%20file%20used%20for?%20-%20MySQL%20Fanboy">Tweet</a></p><br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=27342&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=27342&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2011/02/17/what-is-this-mysql-file-used-for/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Federated Tables</title>
		<link>http://www.mysqlfanboy.com/2010/07/federated-tables/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=federated-tables</link>
		<comments>http://www.mysqlfanboy.com/2010/07/federated-tables/#comments</comments>
		<pubDate>Wed, 07 Jul 2010 15:55:47 +0000</pubDate>
		<dc:creator>Mark Grennan</dc:creator>
				<category><![CDATA[data]]></category>
		<category><![CDATA[ENGINE]]></category>
		<category><![CDATA[federated]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[remote server]]></category>
		<category><![CDATA[Tables]]></category>
		<category><![CDATA[Tips & Tricks]]></category>

		<guid isPermaLink="false">http://www.mysqlfanboy.com/?p=234</guid>
		<description><![CDATA[Your searching for how to create a join across two databases on two different servers and it can&#8217;t be done directly.   select  d1.a, d2.b from db1@server1 join db2@server2 where db1.c = db2.c; does not work.
You learn about federated databases.  The federated storage engine allows accesses     data in tables of remote databases.  Now how do you make it work?
1) Check if the federated storage engine is supported.  Federation is OFF by default!
mysql&#62; show engines;
+------------+---------+----------------------------------------------------------------+
&#124; Engine     &#124; Support &#124; Comment                                                        &#124;
+------------+---------+----------------------------------------------------------------+
&#124; InnoDB     &#124; YES     &#124; Supports transactions, row-level locking, and foreign keys     &#124;
&#124; MyISAM     &#124; DEFAULT &#124; Default engine as of MySQL 3.23 with great performance         &#124;
&#124; BLACKHOLE  &#124; YES     &#124; /dev/null storage engine (anything you write to it disappears) &#124;
&#124; CSV        &#124; YES     &#124; CSV storage engine                                             &#124;
&#124; MEMORY     &#124; YES     &#124; Hash based, stored in memory, useful for temporary tables      &#124;
&#124; FEDERATED  &#124; YES     &#124; Federated MySQL storage engine                                 &#124;
&#124; ARCHIVE    &#124; YES     &#124; Archive storage engine                                         &#124;
&#124; MRG_MYISAM &#124; YES     &#124; Collection of identical MyISAM tables                          &#124;
+------------+---------+----------------------------------------------------------------+

If it is not &#8220;Support&#8221;ed (on) you need to add &#8216;federated=ON&#8216; to the [mysqld] section of your /etc/my.cnf file.  I found this section to be a bit troublesome.  It must be &#8216;=ON&#8217; not &#8216;=YES&#8221; or even &#8216;=on&#8217;.   Most options allow these but the federated options is picky.  I&#8217;m running MySQL Enterprise 5.1.37.sp1.
2) If you don&#8217;t already have the database created, create the database on the storage server.  By &#8216;storage server&#8217; I mean the one where the data will be written to disk.
I like to create a user just for the purpose of connection the federated copy of the database to the true database.  This way, if the password gets changed or the user deleted, the federated system can continue to connect.

mysql&#62; CREATE DATABASE xfiles;
mysql&#62; USE xfiles;
mysql&#62; CREATE TABLE cases(
 Name VARCHAR(20),
 case TINYINT(3),
) ENGINE = INNODB;

3) Now you can create the federated version of your data on the remote system.
mysql&#62; CREATE DATABASE xfiles;
mysql&#62; USE xfiles;
mysql&#62; CREATE TABLE cases(
 Name VARCHAR(20),
 case TINYINT(3),
) ENGINE = FEDERATED
CONNECTION = 'mysql://skiner:c0nsper@fbi/xfiles/cases';
4) Check your work. The table status should show Engine: FEDERATED.
mysql&#62; use xfiles;
mysql&#62; show table status\G
Now you can add records to the table and the data should show up in select on either server.
Enjoy.
]]></description>
			<content:encoded><![CDATA[<p>Your searching for how to create a join across two databases on two different servers and it can&#8217;t be done directly.   <em><strong>select  d1.a, d2.b from db1@server1 join db2@server2 where db1.c = db2.c;</strong></em> does not work.</p>
<p>You learn about federated databases.  The federated storage engine allows accesses     data in tables of remote databases.  Now how do you make it work?</p>
<p>1) Check if the federated storage engine is supported.  <strong>Federation is OFF by default!</strong></p>
<pre>mysql&gt; show engines;
+------------+---------+----------------------------------------------------------------+
| Engine     | Support | Comment                                                        |
+------------+---------+----------------------------------------------------------------+
| InnoDB     | YES     | Supports transactions, row-level locking, and foreign keys     |
| MyISAM     | DEFAULT | Default engine as of MySQL 3.23 with great performance         |
| BLACKHOLE  | YES     | /dev/null storage engine (anything you write to it disappears) |
| CSV        | YES     | CSV storage engine                                             |
| MEMORY     | YES     | Hash based, stored in memory, useful for temporary tables      |
| <strong>FEDERATED  </strong>| <strong>YES     </strong>| Federated MySQL storage engine                                 |
| ARCHIVE    | YES     | Archive storage engine                                         |
| MRG_MYISAM | YES     | Collection of identical MyISAM tables                          |
+------------+---------+----------------------------------------------------------------+
</pre>
<p>If it is not &#8220;Support&#8221;ed (on) you need to add &#8216;<strong>federated=ON</strong>&#8216; to the <strong>[mysqld]</strong> section of your <strong>/etc/my.cnf</strong> file.  I found this section to be a bit troublesome.  It must be &#8216;=ON&#8217; not &#8216;=YES&#8221; or even &#8216;=on&#8217;.   Most options allow these but the federated options is picky.  I&#8217;m running MySQL Enterprise 5.1.37.sp1.</p>
<p>2) If you don&#8217;t already have the database created, create the database on the storage server.  By &#8216;storage server&#8217; I mean the one where the data will be written to disk.</p>
<p>I like to create a user just for the purpose of connection the federated copy of the database to the true database.  This way, if the password gets changed or the user deleted, the federated system can continue to connect.</p>
<pre>
<pre>mysql&gt; CREATE DATABASE xfiles;
mysql&gt; USE xfiles;
mysql&gt; CREATE TABLE cases(
 Name VARCHAR(20),
 case TINYINT(3),
) ENGINE = INNODB;</pre>
</pre>
<p>3) Now you can create the federated version of your data on the remote system.</p>
<pre>mysql&gt; CREATE DATABASE xfiles;
mysql&gt; USE xfiles;
mysql&gt; CREATE TABLE cases(
 Name VARCHAR(20),
 case TINYINT(3),
) ENGINE = FEDERATED
CONNECTION = 'mysql://skiner:c0nsper@fbi/xfiles/cases';</pre>
<p>4) Check your work. The table status should show Engine: FEDERATED.</p>
<pre>mysql&gt; use xfiles;
mysql&gt; show table status\G</pre>
<p>Now you can add records to the table and the data should show up in select on either server.</p>
<p>Enjoy.</p>
<p><img class="alignnone" title="Mark Grennan" src="http://mark.grennan.com/images/MarkGrennanSigniture.bmp" alt="" width="166" height="69" /></p><br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=25251&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=25251&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2010/07/07/federated-tables/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

