hutiefang76 opened a new pull request, #12503: URL: https://github.com/apache/seatunnel/pull/12503
### Purpose of this pull request Fixes #12502. The DuckDB catalog embedded schema and table names directly in metadata-query string literals. A valid name containing an apostrophe produced invalid SQL; an untrusted name could also change the query expression. Both lookup paths now escape embedded apostrophes before formatting the SQL. ### Does this PR introduce any user-facing change? Yes. Catalog table-existence checks and column introspection work for DuckDB schema and table names such as `odd'schema` and `odd'table`. Ordinary names are unchanged. This does not add new connector options. ### How was this patch tested? Added a DuckDB JDBC regression that creates a schema and table with apostrophes, checks table existence and column introspection, and verifies that a name containing SQL operators is still treated as a literal. The new test failed before the fix with a DuckDB parser error and passed after it. ```text JDK 17: mvn -o -pl seatunnel-connectors-v2/connector-jdbc -DskipITs -Dcheckstyle.skip -Dlicense.skip -Dtest=DuckDBCatalogTest test DuckDBCatalogTest: 9 tests, 0 failures, 0 errors ``` ### Check list - [x] Targeted regression passes - [x] No new connector, dependency, configuration, or incompatible change -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
