Fix over when casting from double to decimal.

Change-Id: I6b1f87c9e4334d6f04c515adc5d2fe2c3010a49f
Reviewed-on: http://gerrit.ent.cloudera.com:8080/2494
Reviewed-by: Nong Li <nong@cloudera.com>
Tested-by: jenkins