Skip to content

[PECOBLR-2991] Support JDBC Clob creation and binding - #1651

Open
prathamesh-db wants to merge 2 commits into
databricks:mainfrom
prathamesh-db:codex/pecoblr-2991-clob
Open

[PECOBLR-2991] Support JDBC Clob creation and binding#1651
prathamesh-db wants to merge 2 commits into
databricks:mainfrom
prathamesh-db:codex/pecoblr-2991-clob

Conversation

@prathamesh-db

@prathamesh-db prathamesh-db commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

Description

Adds a mutable in-memory java.sql.Clob returned by Connection.createClob() and supports all PreparedStatement.setClob() overloads by binding CLOB contents as string parameters.

This is one actionable compatibility gap found during the broader PECOBLR-2991 unsupported-operation investigation. Aggregate NOT_IMPLEMENTED_OPERATION telemetry does not by itself attribute events specifically to createClob().

Testing

  • Added CLOB coverage for mutation, substring/range semantics, search, stream flush/close behavior, empty values, oversized values, and free().
  • Extended connection and prepared-statement coverage for open/closed resources, all setClob() overloads, STRING binding, null/empty/freed CLOBs, invalid lengths, and Reader failures.
  • Updated the JDBC method inventory and coverage documentation.
  • mvn -pl jdbc-core test -Dtest=DatabricksClobTest,DatabricksConnectionTest,DatabricksPreparedStatementTest: 114 tests passed.
  • mvn spotless:apply: passed.

Telemetry Errors

  • Not applicable — this PR does not add or change a telemetry-visible error.
  • Applicable — the error uses DatabricksDriverErrorCode where appropriate, and any new code is uniquely numbered and tested.
  • Applicable — maintainer help is requested below to confirm the telemetry taxonomy for the reused error codes.

Additional Notes to the Reviewer

Please confirm or update the telemetry taxonomy for the reused INPUT_VALIDATION_ERROR, INVALID_STATE, CONNECTION_CLOSED, and STATEMENT_CLOSED codes on the new CLOB paths. Review focus: JDBC range semantics and stream mutation behavior.

Signed-off-by: Prathamesh Baviskar <prathamesh.baviskar@databricks.com>
Signed-off-by: Prathamesh Baviskar <prathamesh.baviskar@databricks.com>
@prathamesh-db
prathamesh-db marked this pull request as ready for review August 21, 2026 05:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant