Sei sulla pagina 1di 4

Foreign key : A key defined for a table field is primary key of another table.

It is used to establish relationship between two tables. Value table : A table specified in the definition of a domain and is checked against a field that points this domain. If you define a foreign key for a field that points this domain then the value table is proposed as a check table for foreign key table. Navigations steps to attach value table for a table field employ number(eno) at its domain level. Go with tcode se11. Select the radio button database table yemp5 Click on change button Double click on data element of eno yemp5. Opens a screen. Double click on domain ydeno1. Click on value range tab button. Value table yemp5. Activate.

Navigations steps to create department table: Go with tcode se11. select the radio button ydept05 provide short description- Department table delivery class - A. data browser/table view maint -display maintenance allowed click on fields tab button.

click on technical settings push button. Data class - APPL0 Size category 0 Save it. Go back f3. Select eno field. Click on foreign key button symbol.

Yes. Check table yemp5.

Foreign key field type

checked

key fields.

Unchecked non key fields. Cardinality 1 : CN 1 means there should be exactly one record in primary key table. CN means there can be n number of dependent records in foreign key table for each record in check table. Click on copy. Activate.

To insert records: Go with menu options utilities table contents insert records

Potrebbero piacerti anche