Hi all,I have a process that compares a feature class in SDE to records in a database and if there are any records in the database that do not appear in the feature class these are written out to a dbf file. I then check if there are any rows in the dbf file and if there are create points for these and append them to the feature class in SDE.I use a search cursor in a python script to check if there are any rows in the dbf file. This worked fine with ArcGIS 9.3.1 but now with 10.0 it's acting like it doesn't know the dbf is there. If I export it to a feature dataset it works as well but I really don't want to have to do that.Does anyone know why this is happening or if there is a better way to do this?This is my code at the moment:GEOINVENT_dbf = "\\\\whk2k3sql02\\SDE_DataAdmin\\Transfer\\Import\\Table\\GEOTHERM.dbf"
try:
print '==== Checking for empty DBF'
rows = arcpy.SearchCursor(GEOINVENT_dbf)
row = rows.next()
if row:
AppendAll()
else:
print "No rows in DBF"
except:
arcpy.getmessages()
print '*****ALL DONE'
I've also tried the new fangled way of doing it and it doesn't work either - but not sure if I have it right:GEOINVENT_dbf = "\\\\whk2k3sql02\\SDE_DataAdmin\\Transfer\\Import\\Table\\GEOTHERM.dbf"
try:
print '==== Checking for empty DBF'
for row in arcpy.SearchCursor(GEOINVENT_dbf):
if row:
AppendAll()
else:
print "No rows in DBF"
except:
arcpy.getmessages()
print '*****ALL DONE'
Thanks for your help,Michele.