comparing values of the attribute

Hi,

in an entity i need to check if the value of the perticular attribute is same through out the list without using any looping for comparing how can i achieve it .

Thanks,

Ronan T.

Hi Ronan T,

Try using ListIndexOf Action (from System module). 

Returns the position of the first element that satisfies the given condition, or -1 if no element was found.

https://success.outsystems.com/Documentation/11/Reference/OutSystems_Language/Data/Data_Types/List

Hope it helps,

Assif


Hi Ronan T,

Use group by option to get unique values of attribute from entity and then find any other values exists in the list simply than the value your looking for.

To do group by option follow below steps. 

To find unique Name from Questions entity here, just do group by filter like below.

You will see result like below.


Hope this helps.


Sravan

assif_tiger wrote:

Hi Ronan T,

Try using ListIndexOf Action (from System module). 

Returns the position of the first element that satisfies the given condition, or -1 if no element was found.

https://success.outsystems.com/Documentation/11/Reference/OutSystems_Language/Data/Data_Types/List

Hope it helps,

Assif


Hi assif_tiger,

ListIndexOf() will check if 1st element satisfies the condition here i need to check weather all the elements satisfies the condition and -1 need to be returned of any of 1 element in the list doesn't satisfy the condition.


Thanks,

Ronan T.