Fixed bug causing column to always be 1 in the generated script