Skip to content

Commit 1e2bb37

Browse files
gongchangyouagapple
authored andcommitted
fix bug BASE TABLE as table name (#4217)
1 parent f7ab505 commit 1e2bb37

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

parse/src/main/java/com/alibaba/otter/canal/parse/inbound/mysql/tsdb/DatabaseTableMeta.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,7 @@ private boolean dumpTableMeta(MysqlConnection connection, final CanalEventFilter
209209
for (String schema : schemas) {
210210
// filter views
211211
packet = connection.query("show full tables from `" + schema + "` where Table_type = 'BASE TABLE'");
212+
columnSize = packet.getFieldDescriptors().size();
212213
int tableNameColumnIndex = 0; // default index is 0
213214
List<String> tables = new ArrayList<>();
214215
for (int line = 0; line < packet.getFieldValues().size() / columnSize; line++) {

0 commit comments

Comments
 (0)