Skip to main content
Question

Attribute value replacing with values from another data table attribute

  • June 26, 2017
  • 3 replies
  • 277 views

Forum|alt.badge.img

Hi guys,

I'm stuck with one problem and looking for advice. I have two CSV tables. I'm trying to replace attribute values from first table with ones from second table. Let me try to summarize...

Table no. 1

Parcel number Use of land

1 101

2 101

3 201

3 210

Table no. 2

Use of land Description

101 House

201 Business building

210 Church

So, first table is organized by parcel number and there can be multiple uses of land. There is a more than thousand features in this table. The second table just adds description to the use of land identifier (house for 101 etc.) and has 103 different features.

I need to replace Use of land attribute values in first table with Description attribute values from second table so the first table looks like:

Parcel number Use of land

1 House

2 House

3 Business building

3 Church

I've tried attribute creator with conditional value assining, feature merger and nothing worked so far. I get empty values for Use of land attribute. Hope someone can help. Thanks in advance.

Best regards

JJ

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

3 replies

takashi
Celebrity
  • June 26, 2017

Hi @jjaksic22, I think the general approach is: firstly merge the "Description" from the second table to the first table using "Use of land" as join key, then rename "Description" to "Use of land". Take a look at the FeatureMerger and the AttributeRenamer.

Alternatively, the DatabaseJoiner (called Joiner in 2016 and earlier) or the InlineQuerier can also be used instead of the FeatureMerger.


Forum|alt.badge.img
  • Author
  • June 26, 2017

Thanks @takashi,

it worked with feature merger as you explained.

Best regards


ebygomm
Influencer
Forum|alt.badge.img+46
  • Influencer
  • June 26, 2017

If you have your second table as csv or similar, and it is fixed/constant you could also use an AttributeValueMapper, using the import function to load the values you want to map.

 

The FeatureMerger makes it easier to manage the mapping externally however.