Subject Re: [firebird-support] Re: Views getting corrupt
Author Daniel Rail

At December 29, 2003, 11:02, nols_smit wrote:

> Yes I know the mechanics behind views. But the SQL statements of a
> view must be stored somewhere in a data base table(s) and I suspect
> it is that table(s) getting corrupt because when I open the corrupt
> view (using IBManager) I get the following message:
> frmViewView_2.frmData.DataSelectQuery:
> Arithmetic overflow or division by zero has occured.
> arithmetic exception, numeric overflow, or string truncation

The SQL statement of a view is stored in a system table, and it's the
same table that all your tables main definition(fields are in separate
table) are stored in. So, if it would be that table that would be
corrupt, then you probably would have problems accessing some of your
tables. And, the SQL statement is stored in a text blob.

Does this error appears when you prepare the statement or only when
you execute it?

> If I delete and then re-create the view with it's original SQL
> statements then the problem disappears till I do a Backup and Restore.

What are the settings for the backup and restore processes? If you
use the command line utility GBAK, do you get the same result?

> My guess is:

> The Backup/Restore utility of IBManager's V3.6.5.1 does not match up
> with Firebird SuperServer V1.5 RC6, or
> Firebird SuperServer V1.5 RC6 cannot handle 60 views in a database.

Please try RC8 and then post your result. If you are still having
problems with RC8, then probably someone else would take a closer
look. Who knows, whatever problem you are experiencing might be
corrected in RC8.

Best regards,
Daniel Rail
Senior System Engineer
ACCRA Group Inc. (
ACCRA Med Software Inc. (