You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: flink-cdc-connect/flink-cdc-source-connectors/flink-connector-postgres-cdc/src/main/java/io/debezium/connector/postgresql/connection/PostgresConnection.java
+13-4Lines changed: 13 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -56,7 +56,7 @@
56
56
* {@link JdbcConnection} connection extension used for connecting to Postgres instances.
57
57
*
58
58
* @author Horia Chiorean
59
-
* <p>Copied from Debezium 1.9.8-Final with three additional methods:
59
+
* <p>Copied from Debezium 1.9.8-Final with the following modifications:
Copy file name to clipboardExpand all lines: flink-cdc-connect/flink-cdc-source-connectors/flink-connector-postgres-cdc/src/test/java/org/apache/flink/cdc/connectors/postgres/source/SimilarTableNamesITCase.java
+81-7Lines changed: 81 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,18 @@
48
48
49
49
/**
50
50
* IT tests for FLINK-38965: Fix PostgreSQL CDC connector issue when table names contain underscore
51
-
* that matches other tables due to LIKE wildcard behavior.
51
+
* or percent characters that match other tables due to LIKE wildcard behavior.
52
+
*
53
+
* <p>PostgreSQL LIKE wildcards:
54
+
*
55
+
* <ul>
56
+
* <li>'_' (underscore) matches any single character. E.g., 'user_sink' matches 'userbsink'
57
+
* <li>'%' (percent) matches any sequence of characters. E.g., 'user%data' matches
58
+
* 'user_test_data'
59
+
* </ul>
60
+
*
61
+
* <p>When table names contain these special characters, JDBC metadata queries using LIKE may return
Copy file name to clipboardExpand all lines: flink-cdc-connect/flink-cdc-source-connectors/flink-connector-postgres-cdc/src/test/resources/ddl/similar_names.sql
+37-4Lines changed: 37 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -13,10 +13,12 @@
13
13
-- See the License for the specific language governing permissions and
14
14
-- limitations under the License.
15
15
16
-
-- FLINK-38965: Test case for similar table names with underscore
17
-
-- This tests the fix for PostgreSQL LIKE wildcard matching issue
18
-
-- where underscore '_' matches any single character, causing
19
-
-- 'ndi_pg_user_sink_1' to also match 'ndi_pg_userbsink_1'
16
+
-- FLINK-38965: Test case for similar table names with underscore or percent characters
17
+
-- This tests the fix for PostgreSQL LIKE wildcard matching issue:
18
+
-- - underscore '_' matches any single character
19
+
-- - percent '%' matches any sequence of characters
20
+
-- For example, 'user_sink' may match 'userbsink' (due to '_')
21
+
-- and 'user%sink' may match 'user_test_sink' (due to '%')
0 commit comments