Re: Arithmetic operations and PreparedStatments

2011-02-02 Thread Bryan Pendleton
update T_Professor set weight_In_B_D = weight_In_B_D + ?) - ?) * ?) / ?) where (id = ?) I'm not sure why the arithmetic is carried out using different intermediate scale and precision when you use dynamically substituted values for the constants in your expressions. Did you try using the

Re: Arithmetic operations and PreparedStatments

2011-02-02 Thread Marco Rico-Gomez
update T_Professor set weight_In_B_D = weight_In_B_D + ?) - ?) * ?) / ?) where (id = ?) I'm not sure why the arithmetic is carried out using different intermediate scale and precision when you use dynamically substituted values for the constants in your expressions. Did you try

Arithmetic operations and PreparedStatments

2011-02-01 Thread Marco Rico-Gomez
Hi all, I have an update query that calculates and sets the value of an decimal field in a single row. The field in question is defined as decimal(20, 16) in the database and the calculation is based on arithmetic operations. Here is the SQL statement: --- update T_Professor set weight_In_B_D =