This table provides a list of valid mailpoints. This information is fairly static and requires its own data entry page.
Source romber_mailpoints_tbl.sql
create table romber_location.mailpoints ( locality_id romber_location.location_id not null, mailpoint_code romber_base.generic_name not null, mailpoint_id romber_location.location_id not null, mailpoint_type_id romber_location.location_id not null );
Source romber_mailpoints_pk.sql
alter table romber_location.mailpoints add constraint romber_mailpoints_pk primary key ( mailpoint_id );
Source romber_mailpoints_uk1.sql
alter table romber_location.mailpoints add constraint romber_mailpoints_uk1 unique ( locality_id, mailpoint_code );
Source romber_mailpoints_fk1.sql
alter table romber_location.mailpoints add constraint romber_mailpoints_fk1 foreign key ( mailpoint_id ) references romber_location.locations ( location_id );
Source romber_mailpoints_fk2.sql
alter table romber_location.mailpoints add constraint romber_mailpoints_fk2 foreign key ( mailpoint_type_id ) references romber_location.mailpoint_types ( mailpoint_type_id );
Source romber_mailpoints_fk3.sql
alter table romber_location.mailpoints add constraint romber_mailpoints_fk3 foreign key ( locality_id ) references romber_location.localities ( locality_id );