[
https://issues.apache.org/jira/browse/FLINK-23324?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18096383#comment-18096383
]
Xin Chen commented on FLINK-23324:
----------------------------------
Has anyone encountered the issue where tables with the same name but different
casing are captured simultaneously?
For instance, if a user specifies `table.include.list: t_user_in` and the
PostgreSQL database contains two tables—`t_user_in` and `t_user_IN`— it is
highly likely that both tables will be captured. Here is the relevant code:
{code:java}
com.ververica.cdc.connectors.postgres.source.PostgresSourceBuilder.PostgresIncrementalSource#createEnumerator:
final List<TableId> remainingTables =
dataSourceDialect.discoverDataCollections(sourceConfig);
com.ververica.cdc.connectors.postgres.source.utils.TableDiscoveryUtils#listTables:
Set<TableId> capturedTables =
allTableIds.stream()
.filter(t ->
tableFilters.dataCollectionFilter().isIncluded(t))
.collect(Collectors.toSet());{code}
{{}}
{{}}
{{{}{}}}{{{}{}}}
> Postgres of JDBC Connector enable case-sensitive.
> -------------------------------------------------
>
> Key: FLINK-23324
> URL: https://issues.apache.org/jira/browse/FLINK-23324
> Project: Flink
> Issue Type: Bug
> Components: Connectors / JDBC
> Affects Versions: 1.13.1, 1.12.4
> Reporter: Luning Wang
> Assignee: Luning Wang
> Priority: Major
> Labels: pull-request-available, stale-assigned
>
> Now the PostgresDialect is case-insensitive. I think this is a bug.
> https://stackoverflow.com/questions/20878932/are-postgresql-column-names-case-sensitive
> https://www.postgresql.org/docs/current/sql-syntax-lexical.html#SQL-SYNTAX-IDENTIFIERS
> Could we delete PostgresDialect#quoteIdentifier, make it using super class.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)