| when you CREATE DATABASE PATHNAME, the CDD paths are stored in the
RDB$RELATIONS and RDB$FIELDS table in the database itself.
when you INTEGRATE then only the target is updated. i.e.
in this case
SQL> integrate database file x create pathname cdd$default.x
the target is the CDD.
Take a look at the RDB$CDD_PATH (RDB$DATABASE) and RDB$CDD_NAME (RDB$RELATIONS
and RDB$FIELDS) after the integrate, they will all be empty.
So these links can be reestablished by INTEGRATE when you CREATE DATABASE
PATHNAME, or use ATTACH PATHNAME and reference the CDD using CREATE TABLE ...
PATHNAME or CREATE DOMAIN ... PATHNAME.
Ian
|
|
Ian, thanks
>when you CREATE DATABASE PATHNAME, the CDD paths are stored in the
>RDB$RELATIONS and RDB$FIELDS table in the database itself.
>
>when you INTEGRATE then only the target is updated. i.e.
>in this case
>SQL> integrate database file x create pathname cdd$default.x
>the target is the CDD.
>
>Take a look at the RDB$CDD_PATH (RDB$DATABASE) and RDB$CDD_NAME
>(RDB$RELATIONS
>and RDB$FIELDS) after the integrate, they will all be empty.
This knowledge adds some light, still to dim (dense) to see.
I looked at RDB$CDD_PATH and RDB$CDD_NAME, all null after
create database FILENAME and then integrating.
>So these links can be reestablished by INTEGRATE when you CREATE DATABASE
>PATHNAME, or use ATTACH PATHNAME and reference the CDD using CREATE TABLE
>...
>PATHNAME or CREATE DOMAIN ... PATHNAME.
Still confused. Example why.
Have already created DB via filename, integrated, entered fields/records.
CDO> define field f datatype is real.
CDO> defin record r. id_dom. f. end.
SQL> att 'path cdd$default.mf_personnel';
SQL> create table from cdd$default.r; ! *** works.
SQL> roll;
SQL> disconn all;
CDO delete generic cdd$database mf_personnel;
SQL> integrate datab file pers create path cdd$default.mf_personnel;
SQL> commit;
SQL> disconn all;
SQL> att 'path cdd$default.mf_personnel';
SQL> create table from cdd$default.r;
%CDD-E-DUPGLOBAL, global field with name !AS already exists
-CDD-E-DUPGLOBAL, global field with name ID_DOM already exists
So "some" link does not appear to get reestablished by using
ATTACH PATHNAME and reference the CDD using CREATE TABLE PATHNAME
That missing link appears to be in CDD since after the second integrate
a CDO show field/record does not show a link to the cdd$database entry.
Bottom line, to me anyway. If a DB is not created via PATHNAME and then
integrated and fields/records are cdd "entered" - then if the cdd
cdd$database entry is deleted, then one must delete the records/fields and
re-"enter" them after re-integrating. Too many thens :-)
Maybe that is caused by the fact that as you said:
>when you CREATE DATABASE PATHNAME, the CDD paths are stored in the
>RDB$RELATIONS and RDB$FIELDS table in the database itself.
and those paths are missing due to creating the db via filename and the
integrate can't update some link.
Jerry
|