If in filter

  


Hello, it is possible to use if (,,) on a filter in an aggregate, as in the image.


Hi Rafael,

Yes, you can. You must have to write your If( , , ) and then  = True, i.e. If ( , , ) = True.

Does it solve your problem?


Regards,

António Pereira

António Pereira wrote:

Hi Rafael,

Yes, you can. You must have to write your If( , , ) and then  = True, i.e. If ( , , ) = True.

Does it solve your problem?


Regards,

António Pereira



Sorry, I did not understand, could you give a better example?

If you want to use an If expression in a filter of an aggregate, you must use it as 

If(<condition>,<conditions_is_true>,<condition_is_false>)

The If expression you have in the image is not valid since it doesn't return a Boolean value.

What is your use case? What do you want to filter?

Regards,

António Pereira

António Pereira wrote:

If you want to use an If expression in a filter of an aggregate, you must use it as 

If(<condition>,<conditions_is_true>,<condition_is_false>)

The If expression you have in the image is not valid since it doesn't return a Boolean value.

What is your use case? What do you want to filter?

Regards,

António Pereira

If the condition is "true" it makes a long integer filter for long integer if false false


Hi Rafael,

Try a conditional expression instead. In case you want your condition to work, try this:

ComposicaoVidro.QuantidadePecas = 1 and 
ParametroPedidoItemAltura1.Ident = ComposicaoVidro.ComposicaoParametroIdLargura

Regards,