Subject Re: [firebird-support] renaming tables?
Author Ann W. Harrison
Alexandre Benson Smith wrote:
>
> This was discussed some days back, Ann give a good explanation of the
> difficulties to implement it.
>
> I always asked myself why the system tables don't use a surrogate key
> and if it could be used changing he name of a table or column would be
> trivial since all objects (SP, triggers, views, etc.) would contain the
> objectid instead of the table name. At least this is how I see it, of
> course I could (and probably is) wrong :-)
>

There is a surrogate key which is used for some purposes, but it's
not stable across backup/restore, so it's not suitable for procedures,
views, and other stable structures. You're right that a surrogate
key would make this much simpler, but it would have to work both
for backup/restore and for extracting the metadata and recreating
the database. And probably for extracting metadata from two databases
and merging them - done by a person with a text editor, not
automatically. ... names are pretty easy to track in that case and
surrogates are not.


Best,


Ann