Make Feature Layer fails when comparing fields in a joined table

949
4
10-27-2016 02:48 PM
MaribethPrice
Occasional Contributor

I am working with two congressional district feature classes. I joined them to compare whether the party changed in the last election. I used Select By Attributes, used the expression cd113.party <> cd114.party, and I thought I got a result.  Then I remembered there is no "Create layer from selected features" in Pro, and I tried the same query in Make Feature Layer.  The expression was validated but returned no results. From then on I could not get it to work either in Select By Attributes or Make Feature Layer, in spite of removing/redoing the join, doing the join in the other direction, restarting Pro, restarting Pro with a new project, etc. etc.  It works with a simple value query cd113.party = 'Democrat', but not with a comparison. I also tried it on a different computer with different data and got the same problem, so it seems pretty persistent.  I have checked all the obvious things: the join does work, the query is valid,  there are some districts that changed parties.

Some very strange behaviors coming out of this workflow.

This worked fine in ArcMap (I seem to be saying that a lot these days).

Any one else experienced this?

Tags (2)
0 Kudos
4 Replies
DanPatterson_Retired
MVP Emeritus

did you save the joined data to a new layer so that the joined data persists in the output?  then try on that.  A pain but it should get the job done.

0 Kudos
MaribethPrice
Occasional Contributor

A new layer (e.g. copy/paste into map) or a new feature class (export)? I'm thinking you meant export, but wanted to check.

0 Kudos
MaribethPrice
Occasional Contributor

I've been playing with this for several hours. You workaround of exporting the table (so the fields are there but it is no longer a joined table) does work. However, the scary thing is that the attempt to do SbA or MFL on a joined table appears to corrupt the data and make it unjoinable in the future, even after removing/re-adding the data to a new project (the joined fields are null). That is why the second attempt fails; the join is no longer valid.  I had to replace the data from another source to get the join to work again.  After another run through SbA or MFL on the new data (it works once), the join went bad again.  This is a nasty one.  I put in a tech support request on it.

0 Kudos
DanPatterson_Retired
MVP Emeritus

I just do joins to get files together... once together, then I save to a new featureclass (or shapefile)... I only work with those, I don't use files with joins on them.  Habit perhaps, issues in the past, but storage is cheap and if I don't need it, I dump it.

0 Kudos