Skip to main content
Hi all,

 

I look for ideas to retrieve all values of my attribute if the dissolver count has more han 1.

 

Example :

 

I have 3 shp with ("Name" and "Code" attributes). I connect there with Dissolver transformer (with Dissolver Count Attribute = "NB_Layer" and Liste_Name = "list_layers").

 

I need to add a new attribute with attributeCreator ("LIST_CODE") that contains : 

 

list_layers{0}.Code IF  NB_Layer = 1;

 

list_layers{0}.Code "," list_layers{1}.Code IF  NB_Layer = 2; (concatenation of codes)

 

...;

 

list_layers{0}.Code "," ... "," list_layers{N}.Code IF  NB_Layer = N;

 

 

Thanks an advance.

 

FarFar
Hi,

 

 

if you send the list to a ListExploder you can accomplish this with the regular (i.e. non-list aware) transformers.

 

 

David
Hi,

 

 

If you need to concatenate elements of the list attribute, consider using the ListConcatenator transformer.

 

 

Takashi
Hi,

 

Thank you for help. I use ListConcatenator transformer. it work but i have a doublons into my list. How can I deleted theme before used listconcatenator?

 

 

Thanks an advance.

 

FarFar
Try using the ListDuplicateRemover before concatenating.
Thank you Takashi, it works.

 

 

FarFar
Just a quick tip: type "list" into the workspace to see all the transformers that work on lists:

 

 

 

You can also look under "Lists" in the Transformer Gallery categories:

 

 

 

David
Using exploder prior to removing "doublons" might add unescesarry amount of processing.

 

wen u do this on sets witch are listed on ltiple attributes and even more so when u have nested lists, explosions might yield an enormous amount of objects.

 

 

just a tip/reminder..

Reply