Basically just trying to get python to concatenate a couple of field values into a link, specifically to get it to make a complete link to the image mate online using tax id and swis code found in said table.
Here's my code: *disclaimer* I have very little experience coding...
import arcpy
parcel = "(address to my file here)"
image = "http://property.tompkins-co.org/IMO/propdetail.aspx?swis="
mate = "&printkey="
swis = "SWIS"
sbl = "PRINTKEY"
link = "link"
with arcpy.da.UpdateCursor(parcel, [swis, sbl, link]) as cursor:
for row in cursor:
row[2] == image.string() + row[0] + mate.string() + row[1]
cursor.updateRow(row)
print "finished"
I keep getting the error:
Runtime error
Traceback (most recent call last):
File "<string>", line 11, in <module>
and then a runtime error saying it can't access the file I'm trying to get it to access. Is my code OK, and it just can't access the file? Or is my code incorrect as well?
Thanks in advance,
Tom
Solved! Go to Solution.
== is an equality check
= is for assignment...which is what you want
Ahhh, I see. Thanks!