Closed mbwhite closed 2 months ago
FYI @andrew-coleman
Do you have an full example of this plan? I think the ?
suffix is no longer a thing. It's not present in https://substrait.io/extensions/#function-signature-compound-names anymore.
@vbarua not so much the function name but the arguments...
Unless I've got completely the wrong understanding
Creating a plan from Isthmus, you can see that the name of the function is not:bool
regardless of the nullability. The name used in the extensionFunction
is the substrait.io/extensions#function-signature-compound-names.
./isthmus --create "CREATE TABLE temp (b BOOLEAN, nb BOOLEAN)" "SELECT NOT b, NOT nb FROM temp"
{
"extensionUris": [{
"extensionUriAnchor": 1,
"uri": "/functions_boolean.yaml"
}],
"extensions": [{
"extensionFunction": {
"extensionUriReference": 1,
"functionAnchor": 0,
"name": "not:bool"
}
}],
"relations": [{
...
If I recall correctly ?
in the YAML extension
impls:
- args:
- value: boolean?
name: a
variadic:
min: 0
return: boolean?
indicates that the input argument to the function can be nullable
ah 💡 - makes sense... so my problem is the other way around - what was creating the plan was adding in the ?
that isn't needed.
Thanks @vbarua ... nothing to see here @andrew-coleman ... move along :-)
If I have a plan that contains a reference to the extension:
This is not understood by the Spark library; the
?
suffix is a later spec version after the original Spark-Substrait implementation.Parsing a plan with this type of extension gives: