On 9 Dec 2015, at 13:06, Mike Carey wrote:

+1

Q: Do we need (or want) something similarly generic for null/missing value handling by functions?

I think that’s a little trickier, as we’d probably need something that wraps the function implementation. The null/missing behavior usually does something to the output of the function based on the fact that one of the inputs is null or missing. Maybe some code generation would be helpful here :)

Cheers,
Till

On 12/9/15 11:59 AM, Till Westmann wrote:
Hi,

Ildar has filed ASTERIXDB-1219 in response to a number of issues with built-in functions that do not handle untyped parameters well. While I see the problem, I think that the solution should not be to add conditional code to each implementation. Instead, I think that we should have functions that guarantee the correct input type or type conversion (or throw an error) and rely on the rewriter to ensure that these “enforcing” functions are placed into the plan only if the type check cannot determine that the correct input type is provided.
That way the enforcement code would be only in the plan when needed.

Thoughts?

Cheers,
Till

[1] https://issues.apache.org/jira/browse/ASTERIXDB-1219

Reply via email to