AnsweredAssumed Answered

Python Help needed

Question asked by wfma on Nov 2, 2017
Latest reply on Nov 4, 2017 by xander_bakker

I have a script that populates/updates a field based upon its content. If none of the conditions are true, I need it not to update / return <Null>. 

 

def Reclass(StoryHeight_Copy): 
if (StoryHeight_Copy == "1A"): 
return "1.25" 
elif (StoryHeight_Copy == "1H"): 
return "1.50" 
elif (StoryHeight_Copy == "1T"): 
return "1.75" 
elif (StoryHeight_Copy == "2A"): 
return "2.25"
elif (StoryHeight_Copy == "2H"): 
return "2.50" 
elif (StoryHeight_Copy == "2T"): 
return "2.75" 
elif (StoryHeight_Copy == "3A"): 
return "3.25"
elif (StoryHeight_Copy == "3H"): 
return "3.50" 
elif (StoryHeight_Copy == "3T"): 
return "3.75"

Outcomes