Unique List Operation - Mendix Forum

Unique List Operation

12

It would be really useful if you were able to use a unique list operation which removes any duplicates from a list. This would be much easier to use than the current workaround solution which involves using union with a unique version of the list. 

asked
5 answers

Thanks for your comment Chris, I had been following a solution from a forum post which had suggested you needed to union the list with a version which didn't contain duplicates which seemed wasteful. 

In this case I agree with you, performing a union with itself is the same as a unique list operation.

Created

It is still not clear what the difference is between a new "Make List Unique" action and the current solution "Union" with a list in both parameters. Union with the list itself returns a unique list.

Created

I just had a similiar problem and was looking for this solution. Unfortunately it seems to only be an idea right now...

Created

I had a situation with a many to many association between 2 entities, I was wanting to search an object by a tagging object. So I would create a list and if an object is associated to the tag object I add it to a return list, I then do this for each tag we are searching with, resulting in a list which may have duplicate objects which were returned by multiple tags (therefore added to the list multiple times). I would've found it useful at the end of this to be able to remove the duplicates from the list via a list operation without needing to retrieve a version of the list without duplicates and using union to remove the duplicates.

Created

I always looking about benefit of Idea to vote up for Idea, to be honest I don't see any benefit. Can you explain me what will be benefit of it? I just see duplicate based code (of union) and dropdown with one more pick

Created