Disclaimer: Python Neophyte, Uber-reliant on GUI, working to wean...
I have a Python script for replacing multiple Field values with another table value that was graciously provided by the inimitable DKlassen and seen here:
import arcpy
tablename = "c:\temp\*NAMEOFYOURTABLE*"
fieldvalues = ['fieldname1','fieldname2','fieldname3'......'fieldnameX']
cur = arcpy.UpdateCursor(tablename)
for row in cur:
sourcevalue = row.getValue('*name of field where source value coming from*')
for f in fieldvalues:
row.setValue(f, sourcevalue)
cur.updateRow(row)
Question: After running it it seems to replace all the fieldvalues with f and defaults integers to 0 or 1 (since sourcevalues is a real number between 0-1)--how do I include an operator to multiple for f in fieldvalues by a ratio, or real/float number? Obviously the syntax of f*sourcevalue does not work.