-
-
Notifications
You must be signed in to change notification settings - Fork 257
Description
Submitted by: @pavel-zotov
The following scenario will brings up some strange state of metadata: table T would not be able neither to recreate again nor to be dropped.
C:\FIREBIRD\Data>isql -n
Use CONNECT or CREATE DATABASE to specify a database
SQL> create database 'test5.fdb' pagesize 4096; commit;
SQL> connect test5.fdb user sysdba password masterkey;
Database: test5.fdb, User: sysdba
SQL> recreate table t(id int primary key); -- accidentally forgot to place COMMIT here and recall prev. command
SQL> recreate table t(id int primary key); commit; -- accidentally forgot to delete previous 'recreate' command
Statement failed, SQLSTATE = 42000
unsuccessful metadata update
-too few key columns found for index RDB$PRIMARY1 (incorrect column name?)
SQL> commit; -- since that point the problem persists until b/r will be done
Statement failed, SQLSTATE = 42000
unsuccessful metadata update
-too few key columns found for index RDB$PRIMARY1 (incorrect column name?)
SQL> exit;
Statement failed, SQLSTATE = 42000
unsuccessful metadata update
-too few key columns found for index RDB$PRIMARY1 (incorrect column name?)
C:\FIREBIRD\Data>isql TEST5.FDB -- now launch ISQL *without* switch '-N' but the problem remains
Database: TEST5.FDB
SQL> commit; recreate table t(id int primary key); commit;
Statement failed, SQLSTATE = 42000
unsuccessful metadata update
-cannot create index RDB$PRIMARY3
SQL> exit;