Github user jinfengni commented on a diff in the pull request: https://github.com/apache/drill/pull/377#discussion_r53538246 --- Diff: exec/java-exec/src/main/java/org/apache/drill/exec/expr/annotations/FunctionTemplate.java --- @@ -109,6 +116,16 @@ public int getValue() { public static FunctionCostCategory getDefault() { return SIMPLE; } + } + /** + * The number of argument(s) for a function + * + * This annotation element tells if the number of argument(s) is fixed or arbitrary. Most functions are supposed to + * have fixed number of argument(s); One of the exceptions is String Concatenation function (i.e., concat(...)), which + * can take as many arguments as users would like. + */ + enum FunctionArgumentNumber { + FIXED, VARIABLE --- End diff -- Even under VARIABLE category, there could be function which takes >=0, >=1, etc. For instance, I assume concat will take >=2 arguments. 0 or 1 input should not be valid. Do you have logic to differentiate difference functions?
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---