2

I would like to keep all records when joining fields in ArcMap. I know that I could do this by adding a join, but I would like to use the Join Field tool so that I can dictate which fields are joined and so that it does not change the field name when joined. Is there a way to keep unmatched records when using the Join Field tool?

| improve this question | | | | |
  • After JoinField, can you select the unmatched records and append the input Table? – klewis Nov 17 '16 at 19:52
3

Using python, you could setup your code to specify the input tables and fields, in addition you could specify keep all fields. Here is the syntax table to refer to that uses the join field tool, that I found here or here and a detailed explanation on a another use by GIS SE user Polygeo here

enter image description here

or if you wanted to you can modify your code using the add join field as here

Here is the standard approach using the join data tool in ArcMap:

Once you have selected your files and fields to base your join on, you can keep all records by keeping the default radio button on "keep all records".

Esri, provide an overview on the essentials of joining a table here.

You can see the option here to keep all records, the features that joined and not. You will have null values in the fields with no corresponding match.

enter image description here

| improve this answer | | | | |
  • Although this works, OP wants to use the "join field" tool specifically to specify the fields. An additional work around would be to rename their fields using python to speed up the process or remove the irrelevant fields prior to joining. – GISKid Nov 17 '16 at 18:07
  • Yeah, I specifically wanted to use the "Join Field" tool so as to reduce the amount of modification I would have to do with the table in regards to removing irrelevant fields and naming issues. I'm working with it in a script, but just wanted to throw this question out there before changing a bunch of the code. – mmoore Nov 17 '16 at 18:13
  • I'll update my answer to include that portion to assist with your code. – whyzar Nov 17 '16 at 18:21
  • I get how to perform both methods of joins, but am specifically wondering if anyone knows of a way to keep all records, even unmatched ones, using the Join Field tool. – mmoore Nov 17 '16 at 18:34
  • Have you tried running the script and checking to see if the default is to keep all records, even unmatched ones? I want to believe that is the default when not specifying the filed name. – whyzar Nov 17 '16 at 20:14
1

Say you have 100 records in a table A, and 100 in another table B. If you want to join table A to B, but not all 100 will match to table A, you can select keep all records. Table A will be joined to Table B, the values that do not match values in Table B will be

| improve this answer | | | | |
  • I understand how to add a join and keep all records, but I want to know whether you can keep all records when using the Join Field tool, specifically. – mmoore Nov 17 '16 at 19:43
  • ah ha, not using the Join Field tool as it comes. perhaps look at Add Join tool. – Maksim Nov 17 '16 at 19:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.