Search code examples
mathstored-proceduresoverflowtruncationfirebird1.5

FirebirdDB Cant Run Procedure While Its Backup Db Can


I had a trouble in my database here, I use Firebird 1.5.3 and it work just fine until noe to read or write in normal way, but when I run a procedure, I got blank row result and the following message :

Arithmetic exception, numeric overflow, or string truncation.

SQL Code: -802 IB Error Number: 335544321

So I compared it with my backup db a month ago, it worked just fine, I get data in rows. To ensure my code wasnt change, I copy paste both procedure in WinMerge (diff comparer) but nothing diffrent. To ensure my error came from data, I run my procedure for old dated transaction (1 year old data), still I get those message.

I check the aritmethic logic in procedure, modifying, but no luck. Did anyone can help with this?

Thx a bunch,


Solution

  • After a long tracing into the code and data, I found the obstacle which somehow bugging me out. There was a change in a master data which now has longger character (varchar). In my procedure it was put into a smaller size of varchar, let say 10 character. While new string its about 15. Here goes the error ...or string truncation..... But anyway thanks of your attention to my problem and thanks for the clues you wrote, it save me somehow, give me the idea to trace it up.

    Thx a bunch,