Data Dictionary - Exercise
Title: Database design
Duration: 0.5 days
Note:
1. No table should be client independent.
2. When creating tables/data elements/domains replace ‘XX’ in the name with your employee
number.
3. Create table maintenance views for all the tables.
4. All objects should be created as local objects (development class $TMP).
ZXXEMPL – Employee details
Field Name Key Data Element Description
MANDT X MANDT Client
EMPID X AFFNR Identification number
GRADE SSAL_LEVEL Grade level
LOCATION ARBOR Work location
PU ABTNR Department number
NAME1 AD_NAME1 Name 1
NAME2 AD_NAME2 Name 2
STREET1 AD_STREET Street
STREET2 AD_STRSPP1 Street 2
DISTRICT ORT02 District
STATE REGIO Region (State, Province, County)
COUNTRY LAND1 Country key
ZXXSKIL – Skills for each employee
Field Name Key Data Element Description
MANDT X MANDT Client
EMPID X AFFNR Identification number
POSNR X KPOSNR Item Number
SKILL
EXPR
ZXXPROJ – Projects table
Field Name Key Data Element Description
MANDT X MANDT Client
PROJECT X AM_PSPID Project Definition
PROJ_DESC AUFTEXT Short text
STDAT START_DATE Start date for a project
ENDDAT END_DATE End date for a project
CUSTOMER KUNNR_V Customer number
LOCATION ARBOR Work location
ZXXALOC – Employees allocated to each project
Field Name Key Data Element Description
MANDT X MANDT Client
PROJECT X AM_PSPID Project Definition
EMPID X AFFNR Identification number
SKILL X
STDAT BEGINDATE Start date
ENDAT ENDDATE End date
ROLE
Create Data Elements and assign them wherever they are missing in the design. The specifications for
creation are given below.
Field Name Data Domain Short Text
Element
ROLE ZXXROLE ZXXROLE Role of the employee in the project
SKILL ZXXSKILL CHAR20 Software skills
EXPR ZXXEXPR ZXXNUM Experience in months
3
Create the domain below and assign it to the data element ZXXEXPR.
Domain Data No. of Output Short Text
name type Chars. length
ZXXNUM3 NUMC 3 3 Three-digit numerical value
ZXXROLE CHAR 2 2 Roles
Permitted Values: SE – Software engineer,
PA – Programmer analyst,
PM – Programmer
manager
IMP: The table ZXXEMPL contains all the employees. It is the header table for ZXXSKIL. Create a foreign
key relationship between ZXXEMPL-EMPID and ZXXSKIL-EMPID. Similarly ZXXPROJ is the header
table for PROJECT. Create a foreign key relationship between ZXXPROJ-PROJECT and ZXXALOC-
PROJECT. Similarly create respective foreign keys for ZXXALOC-EMPID and ZXXALOC-SKILL.
Maintain data in all these tables through SM30. Try to create an entry in ZXXALOC for project, which
doesn’t exist in ZXXPROJ. It should display an error.