Skip to content

Commit c2d2ab7

Browse files
committed
Preserve ambiguous JSON string parameters
1 parent 7184786 commit c2d2ab7

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src_cpp/py_connection.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -787,6 +787,9 @@ Value PyConnection::transformPythonValueFromParameter(const py::handle& val) {
787787
auto jsonModule = py::module_::import("json");
788788
try {
789789
auto parsed = jsonModule.attr("loads")(val);
790+
if (pyLogicalType(parsed).containsAny()) {
791+
return Value(LogicalType::JSON(), strVal);
792+
}
790793
return transformPythonValueFromParameter(parsed);
791794
} catch (...) {}
792795
}

0 commit comments

Comments
 (0)