[ 
https://issues.apache.org/jira/browse/NIFI-482?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14593398#comment-14593398
 ] 

Mark Payne commented on NIFI-482:
---------------------------------

A good example of this issue is as follows:

If we have attributes:
a.1 == 245
a.2 == 123
a.3 == 732
a.4 == 343
a.5 == 553
 
Then we evaluate the Expression:
${allMatchingAttributes('a.*'):contains('2'):count():gt(2)}

The expression is valid but returns unexpected results. This happens because 
the 'count' function "reduces" the allMatchingAttributes function. I.e., no 
function should be allowed to be evaluated against the result of 'count' or 
'join'.

There are two issues here really: 1) The Expression is valid, as is, but 
returns incorrect results.  2) We can't do the above.

> users are currently able to evaluate a function against the result of an 
> aggregrate function
> --------------------------------------------------------------------------------------------
>
>                 Key: NIFI-482
>                 URL: https://issues.apache.org/jira/browse/NIFI-482
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Core Framework
>    Affects Versions: 0.0.2
>            Reporter: Ben Icore
>            Assignee: Mark Payne
>             Fix For: 0.2.0
>
>         Attachments: 
> 0001-NIFI-482-Allowed-for-new-literal-function.-Make-expr.patch
>
>
> users should not be able to evaluate a function against the result of an 
> aggregrate function as it will often yield indeterminate results.
>  
> expression should be invalid



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to