diff --git a/README.rst b/README.rst
index a9d3cacb2..faac38fd1 100644
--- a/README.rst
+++ b/README.rst
@@ -9,12 +9,22 @@ Snowflake JDBC Driver
.. image:: http://img.shields.io/:license-Apache%202-brightgreen.svg
:target: http://www.apache.org/licenses/LICENSE-2.0.txt
-
-.. image:: https://maven-badges.herokuapp.com/maven-central/net.snowflake/snowflake-jdbc/badge.svg?style=plastic
- :target: https://repo1.maven.org/maven2/net/snowflake/snowflake-jdbc/
-
+
Snowflake provides a JDBC type 4 driver that supports core functionality, allowing Java program to connect to Snowflake.
+.. |maven-snowflake-jdbc| image:: https://maven-badges.herokuapp.com/maven-central/net.snowflake/snowflake-jdbc/badge.svg?style=plastic
+ :target: https://repo1.maven.org/maven2/net/snowflake/snowflake-jdbc/
+
+.. |maven-snowflake-jdbc-fips| image:: https://maven-badges.herokuapp.com/maven-central/net.snowflake/snowflake-jdbc-fips/badge.svg?style=plastic
+ :target: https://repo1.maven.org/maven2/net/snowflake/snowflake-jdbc-fips/
+
+.. |maven-snowflake-jdbc-thin| image:: https://maven-badges.herokuapp.com/maven-central/net.snowflake/snowflake-jdbc-thin/badge.svg?style=plastic
+ :target: https://repo1.maven.org/maven2/net/snowflake/snowflake-jdbc-thin/
+
+- snowflake-jdbc (fat-jar): |maven-snowflake-jdbc|
+- snowflake-jdbc-fips (FIPS compliant fat-jar): |maven-snowflake-jdbc-fips|
+- snowflake-jdbc-thin (thin-jar): |maven-snowflake-jdbc-thin|
+
Prerequisites
=============
@@ -45,7 +55,7 @@ or for FIPS compliant fat-jar
{version}
-or for experimental thin-jar
+or for thin-jar
.. code-block:: xml
@@ -79,7 +89,7 @@ Build from Source Code
../mvnw org.apache.maven.plugins:maven-install-plugin:3.1.1:install-file -Dfile=target/snowflake-jdbc-fips.jar -DpomFile=./public_pom.xml
cd -
-4. Build the experimental thin-jar and install it in local maven repository by running:
+4. Build the thin-jar and install it in local maven repository by running:
.. code-block:: bash
diff --git a/src/main/java/net/snowflake/client/core/SFArrowResultSet.java b/src/main/java/net/snowflake/client/core/SFArrowResultSet.java
index cbb92bcde..69195e8a4 100644
--- a/src/main/java/net/snowflake/client/core/SFArrowResultSet.java
+++ b/src/main/java/net/snowflake/client/core/SFArrowResultSet.java
@@ -26,7 +26,7 @@
import java.util.stream.Stream;
import net.snowflake.client.core.arrow.ArrayConverter;
import net.snowflake.client.core.arrow.ArrowVectorConverter;
-import net.snowflake.client.core.arrow.StructConverter;
+import net.snowflake.client.core.arrow.StructObjectWrapper;
import net.snowflake.client.core.arrow.VarCharConverter;
import net.snowflake.client.core.arrow.VectorTypeConverter;
import net.snowflake.client.core.json.Converters;
@@ -576,16 +576,19 @@ public Object getObject(int columnIndex) throws SFException {
converter.setSessionTimeZone(sessionTimeZone);
Object obj = converter.toObject(index);
boolean isStructuredType = resultSetMetaData.isStructuredTypeColumn(columnIndex);
- if (type == Types.STRUCT && isStructuredType) {
- if (converter instanceof VarCharConverter) {
- return createJsonSqlInput(columnIndex, obj);
- } else if (converter instanceof StructConverter) {
- return createArrowSqlInput(columnIndex, (Map) obj);
+ if (isVarcharConvertedStruct(type, isStructuredType, converter)) {
+ if (obj != null) {
+ return new StructObjectWrapper((String) obj, createJsonSqlInput(columnIndex, obj));
}
}
return obj;
}
+ private boolean isVarcharConvertedStruct(
+ int type, boolean isStructuredType, ArrowVectorConverter converter) {
+ return type == Types.STRUCT && isStructuredType && converter instanceof VarCharConverter;
+ }
+
private Object createJsonSqlInput(int columnIndex, Object obj) throws SFException {
try {
if (obj == null) {
@@ -605,15 +608,6 @@ private Object createJsonSqlInput(int columnIndex, Object obj) throws SFExceptio
}
}
- private Object createArrowSqlInput(int columnIndex, Map input)
- throws SFException {
- if (input == null) {
- return null;
- }
- return new ArrowSqlInput(
- input, session, converters, resultSetMetaData.getColumnFields(columnIndex));
- }
-
@Override
public Array getArray(int columnIndex) throws SFException {
ArrowVectorConverter converter = currentChunkIterator.getCurrentConverter(columnIndex - 1);
@@ -625,16 +619,19 @@ public Array getArray(int columnIndex) throws SFException {
}
if (converter instanceof VarCharConverter) {
return getJsonArray((String) obj, columnIndex);
- } else if (converter instanceof ArrayConverter) {
- return getArrowArray((List