Analysis of EMPLOYEE_DTL:

  • As of now, this example entity contains only sample of 2 records. In real time, this entity would store millions of records. In order to retrieve the data in a faster way, you have to create an additional column EMP_DTL_ID in EMPLOYEE_DTL and assign it as primary key.
  • In our example, column EMP_DTL_ID will be populated through sequence initiated by a trigger and you can see the sequence code and trigger code in later sections.
  • Eventhough SSN can be added as a primary key in EMPLOYEE_DTL table, you have to add a new column EMP_DTL_ID as the primary key to ensure the fastest retrieval of data.
    Tip:Wherever it is required, you have to create new columns.

Sample Source Data:

Entity Name Table Name Attribute Name Column Name Datatype Null Option Primary Key Foreign Key
Employee Detail EMPLOYEE_DTL Employee Detail Identifier EMP_DTL_ID NUMBER NOT NULL Yes No
Employee Detail EMPLOYEE_DTL Department Number DPTMT_NUM NUMBER(2) NULL No Yes
Employee Detail EMPLOYEE_DTL Gender Code GNDR_CD VARCHAR2(10) NOT NULL No Yes
Employee Detail EMPLOYEE_DTL First Name FRST_NM VARCHAR2(30) NOT NULL No No
Employee Detail EMPLOYEE_DTL Last Name LST_NM VARCHAR2(30) NOT NULL No No
Employee Detail EMPLOYEE_DTL Middle Name MDLE_NM VARCHAR2(30) NULL No No
Employee Detail EMPLOYEE_DTL SSN SSN VARCHAR2(11) NOT NULL No No
Employee Detail EMPLOYEE_DTL Birth Date BRTH_DT DATE NOT NULL No No
Employee Detail EMPLOYEE_DTL Salary Amount SLRY_AMT NUMBER(7,2) NOT NULL No No
Employee Detail EMPLOYEE_DTL DateTime Stamp DTTM_STMP DATE NOT NULL No No



Sample Data Analysis: Continued...       Create Object Commands