diff --git a/arrow/compute/exprs/types.go b/arrow/compute/exprs/types.go index ad6e4e19..9b12b83a 100644 --- a/arrow/compute/exprs/types.go +++ b/arrow/compute/exprs/types.go @@ -113,7 +113,7 @@ func init() { } } - for _, fn := range []string{"and", "or", "not"} { + for _, fn := range []string{"and", "or", "xor", "not"} { err := DefaultExtensionIDRegistry.AddSubstraitScalarToArrow( extensions.ID{URI: SubstraitBooleanFuncsURI, Name: fn}, simpleMapSubstraitToArrowFunc) @@ -122,6 +122,15 @@ func init() { } } + // NOTE: "not" is already registered for conversion to substrait + for _, fn := range []string{"and", "or", "xor"} { + err := DefaultExtensionIDRegistry.AddArrowToSubstrait(fn, + simpleMapArrowToSubstraitFunc(SubstraitBooleanFuncsURI)) + if err != nil { + panic(err) + } + } + for _, fn := range []string{"and_kleene", "or_kleene", "not"} { err := DefaultExtensionIDRegistry.AddArrowToSubstrait(fn, simpleMapArrowToSubstraitFunc(SubstraitBooleanFuncsURI))