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: CHANGELOG.md
+5Lines changed: 5 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,11 @@
4
4
5
5
### Bug Fixes
6
6
7
+
-**[jdbc-v2]** Fixed explicit `FORMAT JSON` queries failing in `executeQuery()` with an unsupported output-format
8
+
error. The driver now exposes the server-rendered JSON as a streaming, single-column `results` string `ResultSet`,
9
+
with one result row per response line, matching the legacy JDBC behavior. Queries without an explicit text format
10
+
continue to use the typed `RowBinaryWithNamesAndTypes` path. (https://github.com/ClickHouse/clickhouse-java/issues/2715)
11
+
7
12
-**[client-v2]** Fixed binary varint decoding for length and count fields so overflowing or overlong values fail with an `IOException` instead of being decoded into corrupted or negative `int` values. (https://github.com/ClickHouse/clickhouse-java/issues/2902)
8
13
9
14
-**[client-v2]** Fixed container query parameters being sent unquoted, so `Client.query(sql, params, settings)` binding
Copy file name to clipboardExpand all lines: docs/features.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -65,7 +65,7 @@ Compatibility-sensitive traits:
65
65
- Prepared statements: Supports `?` parameters through client-side SQL rendering and validates that all parameters are bound before execution.
66
66
- SQL parsing and classification: Classifies SQL to distinguish queries, updates, inserts, `USE`, and role-changing statements, with selectable parser backends.
67
67
- JDBC escape processing: Translates supported JDBC escape syntax for dates, timestamps, and functions before execution.
68
-
- Result set streaming: Streams result sets from ClickHouse binary formats and `FORMAT JSONEachRow`, enforces max-row limits, and manages result-set lifecycle correctly.
68
+
- Result set streaming: Streams result sets from ClickHouse binary formats and `FORMAT JSONEachRow`, and exposes explicit `FORMAT JSON` output as a line-oriented single-column string result set; enforces max-row limits and manages result-set lifecycle correctly.
-`Geometry` has a stable JDBC mapping: metadata reports SQL type `ARRAY` with type name `Geometry`, read paths return nested Java arrays rather than custom wrappers, and write paths depend on the caller preserving the intended point/array nesting shape.
88
88
- JDBC `Geometry` writes share the same ambiguity as the client serializer: variant selection is inferred from nesting depth, so `Ring` versus `LineString` and `Polygon` versus `MultiLineString` are not currently distinguishable when writing through the generic `Geometry` path.
89
89
- JDBC `FORMAT JSONEachRow` support is opt-in through the `jdbc_json_parser_factory` driver property, whose value must be a fully-qualified `JsonParserFactory` class name with a public no-argument constructor; JSONEachRow numeric and structured value behavior follows the selected parser and configured server output settings. Inferred JSON arrays are returned from `ResultSet.getObject(...)` as parser-native `List` values rather than JDBC `Array` values because JSONEachRow does not include element metadata. JDBC temporal typed accessors such as `getTimestamp(...)` are not guaranteed for JSONEachRow result sets; callers that need stable JDBC temporal conversions should use the binary default format or perform application-level conversion from string/object values.
90
+
- JDBC `FORMAT JSON` preserves the server-rendered payload as a line-oriented, single-column `results` result set, with one JDBC row per response line. It does not reconstruct typed ClickHouse columns from the JSON document; callers that need typed column access should omit the explicit format and use the default binary result path.
90
91
- Binary parameters passed through `setBytes()` are encoded as ClickHouse `unhex(...)` expressions rather than text literals; empty byte arrays map to an empty string expression.
91
92
- Stream and reader setters (`setAsciiStream`, `setUnicodeStream`, `setBinaryStream`, `setCharacterStream`, `setNCharacterStream`) are treated as text input encoded with the same string-escaping rules, including length-based truncation when a length is supplied.
92
93
-`getString()` formatting for temporal values is stable output: `Date` uses `yyyy-MM-dd`, `DateTime` uses `yyyy-MM-dd HH:mm:ss`, and `DateTime64` preserves fractional precision, all interpreted in server timezone context where applicable.
0 commit comments