AnsweredAssumed Answered

Else if or maybe Where Clause for Update Cursor.

Question asked by clclark on Apr 25, 2013
Latest reply on Apr 25, 2013 by mzcoyle
I have several conditional statements I want to use to update values in an attribute table. I have been using update cursors as of late with some success. But now I am at a point that I am struggling with. I am able to use single argument conditions like

if row.Bkf_W <= 0:                 row.Width_Cat = 0                 rows.updateRow(row)             elif row.NEAR_DIST > 100:                 row.Snap_Code = 0                 rows.updateRow(row)


But what if I want to check a range of values. Like : Bkf_W > 0 and Bfw_W <=3 then Width_Cat = 1.
Would it be 0 < Bkf_W <= 3, then Width_Cat = 1? I have several of these "range" conditions (8 total) that I want to use to update cursors. Any help would be appreciated!

Outcomes