Table SAP ABAP Web Dynpro

We create two transparent tables, YPERSON and YEU_COUNTRIES. We will use this table later, for our Web Dynpro example.

In the YPERSON table, we want to store the competition candidates. All the candidates should be 18–45 years old and live in an EU country. After creating the table, we have to enter a short description along with the delivery and maintenance

Table maintenance

Table maintenance

We set “Data Browser/Table View Main” ! Display/Maintenance Allowed, to be able to populate our table with values, using “Create Entries”, from the menu.

Then, we will define our table structure. To do this, we select the tab “Fields” and enter the table columns For the fields MANDT and ID_PERSON, we have marked the option “Key”, meaning they are the table keys. The field MANDT is the SAP client field, a three-character client ID. The field “ID_PERSON” represents the candidate’s ID, required to uniquely identify each competition candidate.

Table structure

Table structure

As can be seen, we have used the data elements created hereinbefore: YFIRSTNAME, YLASTNAME, Y_DEINTERVAL, Y_DEFORDOMAIN. When we want to create a new data element, we write its name and, with double-click, we activate the forward navigation. If this data element doesn’t exist, we are asked if we want to create the new data element.

Creating a data element

Creating a data element

Before being able to activate this table, we have to maintain the technical settings

How to maintain the technical settings for the table YPERSON

How to maintain the technical settings for the table YPERSON

We choose a size category 0, because we don’t require many data records. We have to maintain the enhancement category: Extras -> Enhancement Category, from the Menu. We choose the same “Cannot be Enhanced”, because we shouldn’t further extend the table structure.After this, we can activate our table and create the second table YEU_COUNTRIES.

We hold here all the EU Member states information, as follows: country name, year of EU entry, political system, capital city, currency and the flag image name. The structure of this table is presented.

Table structure

Table structure

After this, we have to define a foreign key for the field CHECK_CUR. For this purpose, we use the button “Foreign Keys”. We are asked if we want to use the value table TCURC as check table.

How to create foreign key

How to create foreign key

We need TCUC as a check table, because we want to use its table contents, respectively the Currency Codes.

Currency codes

Currency codes

After we maintain the Technical settings and enhancement category, we can activate the same as for the table YPERSON.

The candidates can live only in an EU country. Therefore, we create a 1 to CN relationship between the tables.

From the table YPERSON field ID_COUNTRY, we create a foreign key.

How to create a foreign key

How to create a foreign key

The system can generate the graphical representation of the relationships we have defined between tables. To show this graph,we use the Button “Graph”.

Foreign key relationship

Foreign key relation ship

We can see our tables YEU_COUNTRIES, YPERSON and the 1:CN relationship.

The table TCUC is the check table for the table YEU_COUNTRIES. To see this relationship also, we have to select the name of YEU_COUNTRIES table and to press the Button “Check Table”.

Foreign key relation ship

Foreign key relation ship

We can create contents withUtilities --> Table content --> Create Entries from Menu

Insert – table YEU_COUNTRIES

Insert – table YEU_COUNTRIES

To display the content: Utilities --> Table content --> Display from Menu.

Select – table YEU_COUNTRIES

Select – table YEU_COUNTRIES

Select – table YEU_COUNTRIES

We can use the transparent tables defined in the ABAP Dictionary to create the context node structure for a Web Dynpro application.



Face Book Twitter Google Plus Instagram Youtube Linkedin Myspace Pinterest Soundcloud Wikipedia

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd DMCA.com Protection Status

SAP ABAP Web Dynpro Topics