i have 2 tables one-to-one relationship (and relationship mandatory 1 side only). follows:
create table prs ( id number(18) not null, common_code varchar2(10), constraint pk_prs primary key (id)); create table rlp { id number(18), spec_code varchar2(20), constraint pk_rlp primary key (id), constraint fk_rlp_prs foreign key (id) references prs(id) on delete cascade);
so problem when inserting record in rlp @ least 1 of common_code
or spec_code
must have value.
is possible enforce constraint using constraint or solution having trigger?
Comments
Post a Comment