Description
Submitted by: Attila Molnár (e_pluribus_unum)
Attachments:
HIBAS.ZIP
Votes: 1
running the next command throws error
EXECUTE BLOCK
AS
BEGIN
rdb$set_context('USER_SESSION', 'VIEW_CREATE_USER', 'SYSDBA');
rdb$set_context('USER_SESSION', 'VIEW_CREATE_PASSWORD', 'masterkey');
EXECUTE PROCEDURE fk_minosites_view_create('*');
END
"This operation is not defined for system tables.
unsuccessful metadata update.
cannot delete.
DOMAIN RDB$245643.
there are 2 dependencies.
At procedure 'FK_MINOSITES_VIEW_CREATE' line: 95, col: 1
At procedure 'FK_MINOSITES_VIEW_CREATE' line: 95, col: 1."
Where RDB$245643 domain comes from? If you see the view source you see specific domain definition, but the view was created with this generated domain.
SELECT *
FROM rdb$relation_fields f
where trim(f.rdb$relation_name) LIKE 'FK_MINOSITES_'
As I see there are two bugs :
#1 : create/alter view not uses the specified domain, but generates a new one and uses that when null casted to domain.
#2 : alter view should not fail ICO domain change (domain drop)