Employee to project activity table (EMPPROJACT)

 

The employee to project activity table identifies the employee who participates in each activity listed for each project. The employee's level of involvement (full-time or part-time) and the activity schedule are also included in the table.

The employee to project activity table is created with the following CREATE TABLE and ALTER TABLE statements:

CREATE TABLE EMPPROJACT       (EMPNO     CHAR(6)          NOT NULL,
       PROJNO    CHAR(6)          NOT NULL,
       ACTNO     SMALLINT         NOT NULL,
       EMPTIME   DECIMAL(5,2)             ,
       EMSTDATE  DATE                     ,
       EMENDATE  DATE                     )


ALTER TABLE EMPPROJACT ADD FOREIGN KEY REPAPA (PROJNO, ACTNO, EMSTDATE) REFERENCES PROJACT ON DELETE RESTRICT

The following aliases are created for the table:

CREATE ALIAS EMPACT FOR EMPPROJACT 

CREATE ALIAS EMP_ACT FOR EMPPROJACT

The table below shows the content of the columns.

Table 1. Columns of the Employee to project activity table
Column name Description
EMPNO Employee ID number
PROJNO PROJNO of the project to which the employee is assigned
ACTNO ID of an activity within a project to which an employee is assigned
EMPTIME A proportion of the employee's full time (between 0.00 and 1.00) to be spent on the project from EMSTDATE to EMENDATE
EMSTDATE Start date of the activity
EMENDATE Completion date of the activity

 

Parent topic:

DB2 Universal Database for iSeries sample tables