Welcome Guest, Not a member yet? Register   Sign In
Insert computed value into SQL database
#5

(01-02-2017, 12:41 PM)PaulD Wrote: As Neuron pointed out, your database table has a percentage column that looks like an integer data type. Your percentage is being calculated to two decimal places. So to insert a decimal into the database you need to define that column as a decimal data type, not an integer. Integers (int) values are whole numbers. Databases distinguish between integers and decimals, and a decimal cannot be an integer. Even 2.0 is not an integer. It is a decimal to one decimal place. Follow Neurons advice and change your column format in the database and see if you get any errors now.

Thanks Paul for the explanation. I will make the change
Reply


Messages In This Thread
RE: Insert computed value into SQL database - by cndunga - 01-02-2017, 09:35 PM



Theme © iAndrew 2016 - Forum software by © MyBB