Skip to main content
Solved

Add attribute value as prefix

  • November 14, 2016
  • 6 replies
  • 128 views

Forum|alt.badge.img

Hi,

I am trying add attribute value as prefix to joined attributes, but I have not succeeded. @bo had quite similar problem Add parameter as prefix...

 

I have created attributes at main.

Then I expose those attributes at custom transformer

But I cant get prefix when I add Joiner

Goal is to have 1_REGISTRATIONDATE, 1_FORMERPARCELLOCUNITID and 2_REGISTRATIONDATE, 2_FORMERPARCELLOCUNITID on the second round and so on.

Best answer by redgeographics

I'm assuming you want to use a custom transformer to loop through the join several times and add a prefix to the resulting attributes based on the loop counter, correct?

If you don't use a prefix in your Joiner but instead use a BulkAttributeRenamer inside your custom transformer it should work.

View original
Did this help you find an answer to your question?

6 replies

redgeographics
Celebrity
Forum|alt.badge.img+49
  • Celebrity
  • Best Answer
  • November 14, 2016

I'm assuming you want to use a custom transformer to loop through the join several times and add a prefix to the resulting attributes based on the loop counter, correct?

If you don't use a prefix in your Joiner but instead use a BulkAttributeRenamer inside your custom transformer it should work.


Forum|alt.badge.img
  • Author
  • November 14, 2016

Correct.

I have tried that, but it didnt work. I also lost values.

I dont know which of there is correct way, but neither works.


redgeographics
Celebrity
Forum|alt.badge.img+49

I got it to work with an attribute. Here's my sample, maybe it's useful.

attr-prefix.fmwt


Forum|alt.badge.img
  • Author
  • November 15, 2016

Thank you, but that does not help. Here is result what I get with your workspace


redgeographics
Celebrity
Forum|alt.badge.img+49

The table view won't accurately reflect this because it's a fixed schema, in your case not all attributes exist on all features. Does the main Feature Information panel show the correct values?


Forum|alt.badge.img
  • Author
  • November 15, 2016

Ok. Yes, correct values are at Feature information panel. Thank you!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings