The join data function does not work properly with my data. How to solve it?

2103
2
06-28-2016 01:24 AM
MichalDudek
New Contributor II

Dear all,

I have a question about the "Join Data" function. I have been trying to join two attribute tables in ArcMap. Both shapefiles contain polygons and the attribute tables have a few fields. The first problem I had was that when I tried to join both tables it did not work. I thought I found the solution (the type of the field in the layer that the join was based on was string and the type of the field in the table to base the join on was double so I changed the string to double adding new field and using the field calculator [old_field]=[new_field] ) and then join. The tables joint but all the fields in the table to base the join on have <null> value which is incorrect because there should be values. I indexed the fields and I used the "join field" data management tool and the result was the same.

I am looking for the ideas what can cause the problem and how to solve it.

Many thanks,

Michał

0 Kudos
2 Replies
JayantaPoddar
MVP Esteemed Contributor

Sometime a value of 1 could be interpreted as 1.000001 or 0.999999 in DOUBLE.

I would suggest you to create a new field (STRING), and migrate the values of the desired field to it using Field Calculator.

Use the STRING fields to join tables.



Think Location
0 Kudos
DanPatterson_Retired
MVP Emeritus

You want to see the type conversion examples here

a = 1234

str(a) => '1234

Calculate Field examples—Help | ArcGIS for Desktop