mpi_relsegattr
The mpi_relsegattr table is used to associate relationship segments to relationship attributes.
- Expanded name
- Relationship segment to relationship attribute
- Table category
- Relationship
- Purpose
- Defines relationship segment and relationship type to relationship attributes.
- Cross-reference
- Not applicable.
Attribute | Description |
---|---|
caudrecno | Creation of this particular record, from mpi_audhead |
maudrecno | Last time the record value was modified, from mpi_audhead |
recstat | Record status; A(ctive) or I(nactive) |
relattrrecno | Relationship attribute record number |
reltypeno | Numeric value for the relationship type |
segcode | Storage segment code from mpi_seghead (specifies physical table) |
attrcode | Attribute code |
attrname | Attribute name |
attrlabel | Attribute label, can be used for reports or interactive screen displays |
attrdesc | Longer text description of the attribute |
nsactive | Determines the number of active values to maintain for this member; the number of allowable active-status instances for an attribute type (applies at a memrecno-atterecno-asaidxno level). A value of 0 retains an indefinite number of active values. A value of 1 retains one active value of an attribute type; the MCA attribute is the active attribute and all previous values become inactive. A value of 2 maintains two active values, and so on. |
nsexists | Determines the maximum number of instances for member attrcodes (applies at a memrecno-atterecno-asaidxno level). The system trims off (deletes) any instances greater than this number. A value of 0 equals no restriction on the number of attribute values stored for member; historical values are note trimmed. A value greater than 0 dictates to the system to trim any historical attribute values over that number. For instance, if you have nsexists set to 3, and you have 3 values for the HOMEADDR attribute, and you update the member and add a fourth value, the oldest value is deleted. |
mpi_relsegattr SQL:
create table mpi_relsegattr
(
caudrecno bigint NOT NULL,
maudrecno bigint NOT NULL,
recstat nchar(1) NOT NULL,
relattrrecno smallint NOT NULL,
reltypeno smallint NOT NULL,
segcode nvarchar(12) NOT NULL,
attrcode nvarchar(12) NOT NULL,
attrname nvarchar(40) NOT NULL,
attrlabel nvarchar(40) NOT NULL,
attrdesc nvarchar(255) NULL,
nsactive smallint NOT NULL,
nsexists smallint NOT NULL
)
create unique index mpi_relsegattr0 on mpi_relsegattr (relattrrecno);
create unique index mpi_relsegattr1 on mpi_relsegattr (attrcode);
create unique index mpi_relsegattr2 on mpi_relsegattr (attrname);
create unique index mpi_relsegattr3 on mpi_relsegattr (attrlabel);