[MDEV-4877] mysqldump dumps all data from a connect table Created: 2013-08-09  Updated: 2013-10-29  Resolved: 2013-10-29

Status: Closed
Project: MariaDB Server
Component/s: None
Affects Version/s: 10.0.3
Fix Version/s: 10.0.5

Type: Bug Priority: Major
Reporter: erkan yanar Assignee: Alexander Barkov
Resolution: Fixed Votes: 0
Labels: connect-engine, mysqldump
Environment:

Ubuntu/Precise/LXContainer



 Description   

mysqldump should behave like with connect as with federated only dumping the structure and not the rows.

DROP TABLE IF EXISTS `federatedconnect`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `federatedconnect` (
  `id` int(11) NOT NULL,
  `id2` int(11) DEFAULT NULL
) ENGINE=CONNECT DEFAULT CHARSET=latin1 `TABLE_TYPE`='mysql' `TABNAME`='aha' `DBNAME`='test' `OPTION_LIST`='user=me,host=10.0.3.191';
/*!40101 SET character_set_client = @saved_cs_client */;

Following should be ommitted

--
-- Dumping data for table `federatedconnect`
--
 
LOCK TABLES `federatedconnect` WRITE;
/*!40000 ALTER TABLE `federatedconnect` DISABLE KEYS */;
INSERT INTO `federatedconnect` VALUES .....

As it will end in at leas dumping other servers data.
Even recovering would get you a lot of errors.

A Fix would be some kind of difficult. While table_type=MySQL,ODBC shoul be omitted. It is hard to handle i.e. table_type=cvs as they can be local tables in the schema too.



 Comments   
Comment by Alexander Barkov [ 2013-10-29 ]

Fixed in 10.0.5

Generated at Thu Feb 08 06:59:53 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.