Not directly related, but can save someone some time with arithmetic overflow errors using Sybase ASE (12.5.0.3).
I set a few default values ββin a temporary table, which I was going to update later, and came across an arithmetic overflow error.
declare @a numeric(6,3) select 0.000 as thenumber into #test --indirect declare select @a = ( select thenumber + 100 from #test ) update #test set thenumber = @a select * from #test
It shows an error:
Arithmetic overflow during implicit conversion of NUMERIC value '100.000' to a NUMERIC field .
What in my head should work, but not like the thenumber column was not declared (or indirectly declared as decimal (4.3)). Thus, you will need to indirectly declare a temp table column with scale and precision in the desired format, since in my case it was 000,000.
select 000.000 as thenumber into #test --this solved it
Hope this helps someone :)
dumle source share