Skip to content

Commit c993372

Browse files
authored
Skip tables on alter query (#66)
1 parent 4938d6c commit c993372

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

mysql_ch_replicator/converter.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -351,6 +351,12 @@ def convert_alter_query(self, mysql_query, db_name):
351351
if table_name.find('.') != -1:
352352
db_name, table_name = table_name.split('.')
353353

354+
if self.db_replicator:
355+
if not self.db_replicator.config.is_database_matches(db_name):
356+
return
357+
if not self.db_replicator.config.is_table_matches(table_name):
358+
return
359+
354360
db_name = strip_sql_name(db_name)
355361
if self.db_replicator and db_name == self.db_replicator.database:
356362
db_name = self.db_replicator.target_database

0 commit comments

Comments
 (0)