Fix typecasting for Oracle types on Java
Fix typecasting for Oracle types on Java

Oracle doesn't really have an Integer type, just a number type
which is returned as bigdecimal, so this uses a horrible hack of
checking the scale of the resulting value, and returning an
integer if the scale is 0.

This also handles an oracle specific type for timestamp columns.

mpalmer/sequel,gferguson-gd/sequel,offshore-safety/sequel,knut2/sequel,t-morgan/sequel,davidbegin/sequel,davidbegin/sequel,seeARMS/sequel,offshore-safety/sequel,freshpay/sequel,Marketcircle/sequel,beni55/sequel,nju520/sequel,offshore-safety/sequel,dennis-d/custom_sequel,t-morgan/sequel,freshpay/sequel,beni55/sequel,nicohvi/sequel,nju520/sequel,reubano/sequel,uhoh-itsmaciek/sequel,gferguson-gd/sequel,seeARMS/sequel,mpalmer/sequel,bigfix/sequel,knut2/sequel,yazshel/sequel,reubano/sequel,dennis-d/custom_sequel,pfarrell/sequel,yazshel/sequel,nicohvi/sequel,chef/sequel,pfarrell/sequel,uhoh-itsmaciek/sequel