You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@arrow.apache.org by "Eduardo Ponce (Jira)" <ji...@apache.org> on 2021/07/19 16:45:00 UTC

[jira] [Commented] (ARROW-13381) [C++][Flight] ArrayFromJSON doesn't work for float value dictionary type

    [ https://issues.apache.org/jira/browse/ARROW-13381?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17383446#comment-17383446 ] 

Eduardo Ponce commented on ARROW-13381:
---------------------------------------

The error occurs because there is no dict converter implemented for floating-point types in [*ipc/json_simple.cc*|https://github.com/apache/arrow/blob/master/cpp/src/arrow/ipc/json_simple.cc#L779-L798].

The code path is as follows: *Call to ArrayFromJSON(...)* -> [ArrayFromJSON(DataType, string_view)|https://github.com/apache/arrow/blob/master/cpp/src/arrow/testing/gtest_util.cc#L406] -> [ArrayFromJSON(DataType, string_view, Array)|https://github.com/apache/arrow/blob/master/cpp/src/arrow/ipc/json_simple.cc#L870] -> [GetConverter(DataType, Converter)|https://github.com/apache/arrow/blob/master/cpp/src/arrow/ipc/json_simple.cc#L808] -> [GetDictConverter|https://github.com/apache/arrow/blob/master/cpp/src/arrow/ipc/json_simple.cc#L763]

> [C++][Flight] ArrayFromJSON doesn't work for float value dictionary type
> ------------------------------------------------------------------------
>
>                 Key: ARROW-13381
>                 URL: https://issues.apache.org/jira/browse/ARROW-13381
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: C++, FlightRPC
>            Reporter: Niranda Perera
>            Priority: Minor
>
> The following code returns a NotImplemented error. It works without a problem for int/ string type values.
> {code:java}
> auto arr = ArrayFromJSON(dictionary(int32(), float32()), "[1, 1000]");
> // output 
> -- Arrow Fatal Error --
> NotImplemented: JSON conversion to dictionary<values=float, indices=int32, ordered=0> not implemented
> Process finished with exit code 134 (interrupted by signal 6: SIGABRT)
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)