Subject Re: [firebird-support] Limit change metadata
Author Ann W. Harrison
At 04:56 PM 12/1/2004, piraju1379 wrote:

>Is the Limit 256 change metadata in system table?

You can make only 255 changes to a table (add field, drop
field, alter field type/size) before you must backup and
restore the database. In InterBase, activating and deactivating
a trigger counted, but in Firebird it doesn't.

>How obtain value actual of the limit 256 change in metadata?

The restriction comes from the size of the format version number
on a table, which is a byte. The format version is part of every
record stored, and that part of the ODS was designed when a byte
was important. If you want to check the current format version
number for a table get it's relation id

select rdb$relation_id from rdb$relations
where rdb$relation_name = 'MY_TABLE'

Then lookup the highest format number

select max(rdb$format) from rdb$formats
where rdb$relation_id = <whatever that number was>

Regards,


Ann