With the right regular expression, you can strip all the leading zeroes from your data fields with just a few characters:

valueWithoutZeroes="$(echo $valueWithZeroes | sed 's/0*//')"

Source: www.askdavetaylor.com