I am trying to calculate field test2
with only the numeric values from a string field test
. The entire script is like:
def makestr(test)
list=[]
for s in test:
if s.isdigit():
list.append(s)
for a in list:
str=''.join(list)
But I keep getting an error:
Any ideas?