You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@arrow.apache.org by "Joris Van den Bossche (Jira)" <ji...@apache.org> on 2022/10/11 09:47:00 UTC
[jira] [Updated] (ARROW-17963) [C++] Implement casting to dictionary type (dictionary_encode as a cast)
[ https://issues.apache.org/jira/browse/ARROW-17963?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Joris Van den Bossche updated ARROW-17963:
------------------------------------------
Summary: [C++] Implement casting to dictionary type (dictionary_encode as a cast) (was: [C++] Implement cast_dictionary for string)
> [C++] Implement casting to dictionary type (dictionary_encode as a cast)
> ------------------------------------------------------------------------
>
> Key: ARROW-17963
> URL: https://issues.apache.org/jira/browse/ARROW-17963
> Project: Apache Arrow
> Issue Type: Improvement
> Components: C++
> Reporter: Will Jones
> Priority: Major
> Labels: Kernels
> Fix For: 11.0.0
>
>
> We can cast dictionary(string, X) to string, but not the other way around.
> {code:R}
> > Array$create(c("a", "b"))$cast(dictionary(int32(), string()))
> Error: NotImplemented: Unsupported cast from string to dictionary using function cast_dictionary
> /Users/willjones/Documents/arrows/arrow/cpp/src/arrow/compute/function.cc:249 func.DispatchBest(&in_types)
> > Array$create(as.factor(c("a", "b")))$cast(string())
> Array
> <string>
> [
> "a",
> "b"
> ]
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)