Comparing fields from two Feature Classes.

Discussion created by dalejs on Jun 6, 2014
Latest reply on Jun 8, 2014 by kimo
Hi, and thank you for taking your time to look at my post.  I am new to Python(I was in a class at this time a week ago).  I am looking for a Python function(?) to compare a field in two seperate feature classes.  arcpy.SelectLayerByAttribute_management looks close to what I am looking for, but I do not think it will work for my use.  I cannot join the layers.

Here is my scenario.  I have an address feature class and street feature class, the address feature class has a field that is tied to the street the address is located.  So all addresses on Main St. have a StreetID field, the number in the StreetID field should match the ID field of Main St. in the Street feature class.

I want to create a new layer/feature class of the Addresses where the StreetID in Addresses does not match the ID of the street in Streets.

In VB.net I had it looping through the streets, searching the addresses that matched the street name (street, city, state, zip) and then comparing the StreetID - ID fields, writing errors to a selection set then creating the layer.

In my brief experience with arcpy I would think there is a funtion that allow me to do that. 

Not looking for code, just wanting to find out if there is a function I can work with.

Thanks, Dale