Bug #671 mysqlbinlog's --table option gives strange (wrong?) output
Submitted: 18 Jun 2003 6:32 Modified: 1 Jul 2003 3:28
Reporter: Guilhem Bichot Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Replication Severity:S3 (Non-critical)
Version:4.0 OS:Any (all)
Assigned to: Victor Vagin CPU Architecture:Any

[18 Jun 2003 6:32] Guilhem Bichot
Description:
This option is apparently intended to get a "raw (binary?) dump" of a table.
The results are surprising.
Monty in Warsaw about this problem: "if it does not work then remove the option". Now we just have to decide if we judge it works for MyISAM or not (we know it cannot work for InnoDB), and if we judge it does not work, then we have to remove the option (maybe we will reintroduce it when online backup works in 5.0, but for 4.0 and 4.1 we should remove it).

How to repeat:
use test;
create table v(a int);
insert into v values(1); #do it several times.
Then

/m/mysql-4.1/client/mysqlbinlog -uroot -ttest.v
CREATE TABLE `v` (
  `a` int(11) default NULL
) TYPE=MyISAM CHARSET=latin1ýýýýýýýýýýýýýýý[guilhem@gbichot2 1]$ 

The 'ý's are the raw binary content of the table I think, but this seems unusable to me. And btw this option seems a bit useless to me.

With InnoDB (but it's a normal problem, nothing to fix (COM_TABLE_DUMP works for MyISAM only), except that it may confuse users who try, because it's not documented that it does not work with InnoDB):
[guilhem@gbichot2 1]$ /m/mysql-4.1/client/mysqlbinlog -uroot -ttest.v
CREATE TABLE `v` (
  `a` int(11) default NULL
) TYPE=InnoDB CHARSET=latin1ÿ#HY000Got error -1 from storage engine
and it hangs here.

Suggested fix:
probably remove the option from mysqlbinlog.
[30 Jun 2003 2:13] Victor Vagin
mysqlbinlog --port=$port --table=test.v

can be replaced with:

mysqldump --port=$port test v
[1 Jul 2003 3:28] Victor Vagin
Thank you for your bug report. This issue has been fixed in the latest
development tree for that product. You can find more information about
accessing our development trees at 
    http://www.mysql.com/doc/en/Installing_source_tree.html

option mysqlbinlog --table is removed