diff --git a/flink-connector-sqlserver-cdc/src/main/java/com/ververica/cdc/connectors/sqlserver/source/utils/SqlServerUtils.java b/flink-connector-sqlserver-cdc/src/main/java/com/ververica/cdc/connectors/sqlserver/source/utils/SqlServerUtils.java index 9f03bde2f..9743384c6 100644 --- a/flink-connector-sqlserver-cdc/src/main/java/com/ververica/cdc/connectors/sqlserver/source/utils/SqlServerUtils.java +++ b/flink-connector-sqlserver-cdc/src/main/java/com/ververica/cdc/connectors/sqlserver/source/utils/SqlServerUtils.java @@ -200,7 +200,7 @@ public class SqlServerUtils { /** Fetch current largest log sequence number (LSN) of the database. */ public static LsnOffset currentLsn(SqlServerConnection connection) { try { - Lsn maxLsn = connection.getMaxLsn(connection.database()); + Lsn maxLsn = connection.getMaxTransactionLsn(connection.database()); return new LsnOffset(maxLsn, maxLsn, null); } catch (SQLException e) { throw new FlinkRuntimeException(e.getMessage(), e);