This table provides an orderd list of meta classes associated with an item layout.
Source romber_item_layout_classes_tbl.sql
create table romber_item.layout_classes ( item_layout_id romber_item.layout_id not null, item_class_seq_num int not null, meta_class_id romber_meta.class_id not null );
Source romber_item_layout_classes_pk.sql
alter table romber_item.layout_classes add constraint romber_item_layout_classes_pk primary key ( item_layout_id, item_class_seq_num );
Source romber_item_layout_classes_uk1.sql
alter table romber_item.layout_classes add constraint romber_item_layout_classes_uk1 unique ( item_layout_id, meta_class_id );
Source romber_item_layout_classes_fk1.sql
alter table romber_item.layout_classes add constraint romber_item_layout_classes_fk1 foreign key ( item_layout_id ) references romber_item.layouts ( item_layout_id );
Source romber_item_layout_classes_fk2.sql
alter table romber_item.layout_classes add constraint romber_item_layout_classes_fk2 foreign key ( meta_class_id ) references romber_meta.classes ( meta_class_id );
Source romber_item_layout_classes_load.sql
insert into romber_item.layout_classes ( item_layout_id, item_class_seq_num, meta_class_id ) values ( ( select item_layout_id from romber_item.layouts where item_layout_code = 'DEFAULT' ), 1, ( select meta_class_id from romber_meta.classes where meta_class_code_singular = 'ITEM_INSTANCE' ) ); insert into romber_item.layout_classes ( item_layout_id, item_class_seq_num, meta_class_id ) values ( ( select item_layout_id from romber_item.layouts where item_layout_code = 'DEFAULT' ), 2, ( select meta_class_id from romber_meta.classes where meta_class_code_singular = 'ITEM_TYPE' ) ); insert into romber_item.layout_classes ( item_layout_id, item_class_seq_num, meta_class_id ) values ( ( select item_layout_id from romber_item.layouts where item_layout_code = 'DEFAULT' ), 3, ( select meta_class_id from romber_meta.classes where meta_class_code_singular = 'ITEM_CATEGORY' ) ); insert into romber_item.layout_classes ( item_layout_id, item_class_seq_num, meta_class_id ) values ( ( select item_layout_id from romber_item.layouts where item_layout_code = 'DEFAULT' ), 4, ( select meta_class_id from romber_meta.classes where meta_class_code_singular = 'WEB_SITE' ) ); insert into romber_item.layout_classes ( item_layout_id, item_class_seq_num, meta_class_id ) values ( ( select item_layout_id from romber_item.layouts where item_layout_code = 'DEFAULT' ), 5, ( select meta_class_id from romber_meta.classes where meta_class_code_singular = 'BUSINESS_REGION' ) ); insert into romber_item.layout_classes ( item_layout_id, item_class_seq_num, meta_class_id ) values ( ( select item_layout_id from romber_item.layouts where item_layout_code = 'DEFAULT' ), 6, ( select meta_class_id from romber_meta.classes where meta_class_code_singular = 'BUSINESS' ) );