Comment Comment by knightni You're running into the fact that Postgres doesn't automatically cast ints to floats - so 1/50 = 0. Try using 1.0/50.0 instead. parent knightni 13 years ago