Joins do not work in Modelbuilder 10

11276
34
02-07-2011 01:07 PM
TomMagdaleno
Occasional Contributor III
So far I have been working on fixing models almost exclusively for a week!  I have models with multiple joins and calculations and ever since we upgraded to 10 they do not work.  I have a "Remove Join" and then a second Join, but I get errors saying that my inputs are not current.  When I do a validation it will tell me so and so table is already joined.  So I have to exit out, delete the joined table then open the model again to validate the data.  Now the data before the join won???t work because it thinks the ???field name does not exist??? because the table is no longer joined! 

MODELBUILDER USED TO BE SMARTER THAN THIS!

Now I have to break up my models into several models and export out intermediate data so I can work with it.  This is what I was told to do by tech support.  This is driving me nuts!

Also, ???Make Table View??? changes every time the model is validated.  If I have only a few columns checked in the table view, then run a validate it will recheck all the columns and screw up my output.  Tech support tells me to not use .dbf tables, to put everything in a geodatabase, do permanent joins and export out intermediate data.  This is getting to be WAY more steps then just doing a few simple joins and calculates in ArcMap.  Is anyone else dealing with this crap?
0 Kudos
34 Replies
Corey_C_Denninger
New Contributor
Just an update, perhaps this has been fixed in the later ArcGIS 10 versions (we just got it), but I unchecked the 'Maintain fully qualified field names' and it seemed to work.  I had an Add Join, even though I performed a Remove Join it was keeping the full field names.  Once I unchecked, it worked great.


For those still banging their heads against the wall:

I have a call into ESRI about this issue but I've made so headway for those that need a quick fix.
On my ArcGIS 10 SP2 the 'Add Join' tool will always add fully qualified field names (aka alias, tablename.fieldname, tablename_fieldname) regardless of what the environment settings are in the Canvas view.

If I right click on the model in the toolbox and got to model properties, then 'Maintain fully qualified field names' is unchecked - see attached. Running the model results in the tablename.fieldname outputs.

Now if I run the model from ArcCatalog and on the parameters page look at the environment settings the 'Maintain fully...' is checked - see second attached. If I uncheck this box and run the model then the fields are the fieldnames without the tablename. This setting has to be manually changed each time the model is run.

The two areas to set environment parameters do not respect eachother. I have also tried 10+ combinations of check/uncheck/save/apply/uncheck/save/validate/run/save in the Canvas view without anything working.

This is the only way I can get 'Add join' to work the way I want it to in model builder 10.
This is of course a huge pain as I can no longer step through models in the canvas view as I did so effortlessly in 9.3.1 but hopefully this helps anyone else experiencing my frustrations with model builder 10 and 'Add Join'. I'll update if ESRI Canada finds a solution for me.
0 Kudos
AZendel
Occasional Contributor III
I'm using ArcGIS 10 SP2 and I encountered a problem with the join table tool today (9/9/11).  This problem occurred when rerunning the model from the model builder window, not when running the model from the dialog that opens when you double click the model in a toolbox.  My model crashed downstream of the join tool due to an error of mine in the calculate field tool.  So I closed the dialogue that prints all of the data from the geoprocessing model as it runs and returned to the model builder itself.  I corrected the error in the calculate field tool and validated the model so I could re-run it.  But the join tool and everything downstream turned white - indicating an error at the add join tool.  I double clicked the add join tool and the red error symbol was present in the add join dialog box.  When I hovered over it, it reported that the join table was already joined to the target feature class. 

It seems to me that the validate model process doesn't clear out joins from previous sessions.  I think it should.  When you validate an entire model, it's going to run from the very beginning next time that you run it.  So shouldn't model builder detect this and remove all of the joined tables as it validates the model?

I also tried saving, closing, and rerunning the model - no dice.  So I closed and restarted ArcCatalog, thinking that something in memory was hanging onto the join.  No dice.  Then I added the remove join tool immediately upstream of the add join tool and that worked.  Of course, I had to remove it for subsequent runs of the model.  This seems like a bug to me, but maybe I'm missing something.   I hope this helps anybody who is encountering a similar issue.
0 Kudos
ShitijMehta
Esri Regular Contributor
From within ModelBuilder:
You have to use the Remove Join tool to remove the join. If you save the model after running once it will save the state of all the tools and the intermediate data unless you go click model menu> delete intermediate data.

or

Rerun the model uptill the tool before the Add Join tool and hit validate. Now rerun the whole model.
0 Kudos
NathenHarp
New Contributor II
I also have problems with AddJoin/JoinField and CalculateField in ModelBuilder. The model works with ~20 records but hangs on ~1,000 or more. A workaround is exporting out the intermediate data as seperate steps and calculating the field in ArcMap. Failed model is attached.
0 Kudos
ShitijMehta
Esri Regular Contributor
Can you also share your model with your data? It would be useful in finding the problem and suggesting a solution.
0 Kudos
PatriciaMoehring
Occasional Contributor
OMG, I'm new to modelbuilder and I think I made a huge error.  I used the JoinField tool instead of the AddJoin tool because I couldn't figure out why I couldn't do what I thought the AddJoin tool should have been able to do.  So, now I can't seem to RemoveJoin -- what's a newbie to do?

And thanks for all this other good stuff.  I think I can set it up right now but it would be nice if the AddJoin worked correctly.

New to ModelBuilder not New to ArcGIS; I just finally have a little time to play and get in trouble!:)
0 Kudos
JimW1
by
Occasional Contributor II
OMG, I'm new to modelbuilder and I think I made a huge error.  I used the JoinField tool instead of the AddJoin tool because I couldn't figure out why I couldn't do what I thought the AddJoin tool should have been able to do.  So, now I can't seem to RemoveJoin -- what's a newbie to do?

And thanks for all this other good stuff.  I think I can set it up right now but it would be nice if the AddJoin worked correctly.

New to ModelBuilder not New to ArcGIS; I just finally have a little time to play and get in trouble!:)


Oh I hate to say it but from my experience your only recourse is to delete the joined fields or revert back to an older version of your data. I've done the same thing one foggy Monday morning at least once 🙂
0 Kudos
MayaThomas
New Contributor
OMG, I'm new to modelbuilder and I think I made a huge error.  I used the JoinField tool instead of the AddJoin tool because I couldn't figure out why I couldn't do what I thought the AddJoin tool should have been able to do.  So, now I can't seem to RemoveJoin -- what's a newbie to do?

And thanks for all this other good stuff.  I think I can set it up right now but it would be nice if the AddJoin worked correctly.

New to ModelBuilder not New to ArcGIS; I just finally have a little time to play and get in trouble!:)


I think I experienced this same frustration a few minutes ago and had an epiphany - you have to create a feature layer or table view. Then AddJoin and RemoveJoin work correctly. This is essentially the same as doing a tabular join in ArcMap. ArcMap creates these layers/table views automatically. In ModelBuilder, you have to make them yourself.
0 Kudos
JimW1
by
Occasional Contributor II
So much time has passed on this thread and I now sit in 10.1 with joined field names that will only 'Maintain Fully...'
Is there a practical use for this? Why is it the default?

The joins are still a mess and now Model Builder likes to lock itself. There's only one instance of ArcMap open but if I don't manually refresh the table views (by opening the tables from the TOC) it'll lock up on me.

Could someone please tell me why you'd want your field name to be something like [TEMP_PIVOT_GROUPBYFID.FID_Buildings] instead of [FID_Buildings]? I'm at a loss as to how anyone who'd be doing a join in Model Builder wouldn't know the source tables nor could look at the inputs to Model Builder to figure them out. Why is this the default since 10? What big ESRI customer asked for this change and why does it persist?

Enough ranting. Cheers to those that feel my pain.
JasonBalmut
Occasional Contributor III

It's now 2015 and this thread topic, along with its precursor, has no real solution.  That's 11 years with no fix.  A decade is a reasonable window for improvement and yet the geoprocessing tools still don't work as it should.

I added this to ArcGIS Idea today, March 6, 2015.

0 Kudos