0% found this document useful (0 votes)
61 views

How To A Create Table

Step 1: Enter transaction code SE11 to create a table. Step 2: Enter the table name starting with Y or Z. Click "Create" to generate the table. Step 3: Add fields to the table including a mandatory client field (MANDT). Select delivery class A for application tables. This document provides steps to create a database table in SAP, including entering the transaction code, specifying the table name and fields, and selecting delivery class and other properties.

Uploaded by

bhuvan9032
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
61 views

How To A Create Table

Step 1: Enter transaction code SE11 to create a table. Step 2: Enter the table name starting with Y or Z. Click "Create" to generate the table. Step 3: Add fields to the table including a mandatory client field (MANDT). Select delivery class A for application tables. This document provides steps to create a database table in SAP, including entering the transaction code, specifying the table name and fields, and selecting delivery class and other properties.

Uploaded by

bhuvan9032
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 24

How to a Create Table

Step 1: Enter transaction code SE11 from where we can create a table and press Enter.

Step 2: You will get below window. Enter the table name which you want to create.

Note: Table name should start with Y or Z only.


Step 3: Click on Create button. You will get below window.

Step 4: Enter Short Description. Enter Delivery Class as A. Select Display/Maintenance Allowed from the
dropdown Data Browser/Table View Editing.
What is Delivery Class?
Delivery class is how database table is going to be transported during installation, upgrade, and copies
within landscapes, clients and customer systems.

Types of Delivery Class


There is a total of 7 Delivery Classes in SAP ABAP.

1. A

If we select this delivery class type that means we are creating application table which contain master data
or transaction data. Application Tables are transported to the customer as empty.

Master data means the data which rarely gets changed. For example, Customer data, Address data.

Transaction Data means the data which change frequently. For example, Sales Data.

2. C

These are client specific customer table used for customize application. Here data is only entered by the
customer.

3. L

These tables used to store temporary data. Tables are delivered to customer as empty.

4. G

Customer table where SAP can add data but can not modify or delete it.

5. E

System table in which customers can make entries. System tables are delivered with some data.

6. S

These tables are System table delivered by SAP with predefined data as part of system.

7. W

System table for system administration data. A system table in the delivery class W usually delivered with
predefined data by SAP.

Data Browser/Table View Editing


Data browser/table view editing allows you to edit the contents of the table, create entries into the table,
delete entries from the table using table maintenance tools.

Table maintenance tools are data browser (Transaction SE16), table/view maintenance (Transaction
SM30/SM31) and Generate Table maintenance Dialog (Transaction SE54).
There are four options in data browser/table view editing

1. Display/Maintenance allowed with restrictions

If we select this option in dropdown, using data browser (Transaction SE16) display of the table contents is
possible but no maintenance is allowed.

Using table/view maintenance (Transaction SM30/SM31) display and maintenance of the table/view is not
allowed.

Using Generate Table Maintenance Dialog (Transaction SE54) tool only display of the table contents is
allowed no maintenance.

2. Display/Maintenance Allowed

If we select this option in dropdown, using data browser (Transaction SE16) display of the table contents
as well as maintenance of table/view is allowed.

Using table/view maintenance (Transaction SM30/SM31) display and maintenance of the table/view is
allowed.

Using Generate Table Maintenance Dialog (Transaction SE54) tool display of the table contents and
maintenance is allowed.

3. Display/Maintenance Not Allowed

If we select this option in dropdown, using data browser (Transaction SE16) display of the table contents
as well as maintenance is not allowed.

Using table/view maintenance (Transaction SM30/SM31) display and maintenance of the table/view is not
allowed.

Using Generate Table Maintenance Dialog (Transaction SE54) tool display of the table contents as well as
maintenance is not allowed.

4. Only Display Allowed

If we select this option in dropdown, using data browser (Transaction SE16) display of the table contents is
possible but no maintenance is allowed.

Using table/view maintenance (Transaction SM30/SM31) display is allowed and maintenance of the
table/view is not allowed.

Using Generate Table Maintenance Dialog (Transaction SE54) tool only display of the table contents is
allowed no maintenance.
Step 5: Press Save button and save it in your existing package. Click on Fields Tab. You will get below
window.

Step 6: Add fields into the table. First add MANDT field and make it key also add the MANDT as a data
element. Press Enter.
What is MANDT?
MANDT is a client field. Here client means area. If we have MANDT field in our table that means table is
client dependent and if we don’t have that field that means table is client independent.

Client dependent means if we create table in one client it will be accessible only in that client and it is not
accessible in other clients.

Client independent means if we create table in one client it will be accessible in that client and other client
also.

MANDT is a standard data element which is already created by SAP. Hence, we are reusing it here.

Step 7: Double click on MANDT element. Below window will get open. Here we can see MANDT is a
data element and it is already created.

Here we can see that MANDT domain is already created by SAP.

Note: To add field into table first we require to create Data Element first.
 

How to Create Data Element


Two ways we can create Data Element

First Method
Step 1: Add Field name as Employee_id and Data element name as ZAK_Employee_id.

Step 2: Double click on ZAK_employee_id data element. It will show you below window. Click on yes
and save it in your package.

Step 3: Then it will ask you to create data element. Click on yes.
Step 4: Give Short Description.

Step 5: Here to create data element we need to specify the data type. That means which type of it is.

In Elementary Type, we can specify type by creating domain or using built-in type.

First, we will see built-in type.

Click on built-in type and then click on data type field. Just beside the data type field there is input help
means there is a list of data type that we can use it.

Below you can see the list of data type.


Step 6: I want employee_id field of type CHAR hence I selected CHAR.

Step 7: Specify length of the value which we want to store in employee_id field.

Give length 20 if you select numeric data type then you can also specify decimal places.
Step 8: Click on Field Label tab. It is compulsory to give field label. It is used to display heading for that
particular field in the report.

Step 9: Save it in your package and activate it.


Step 10: Click on back. Here your data element is created.

How to Create Data Element


Second Method
Step 1: Go to transaction SE11.

Step 2: Click on Data Type


Step 3: Here we are creating second data element for employee_name field which we will add in our table.
Enter the Data Element name. I have given ZAK_DE_EMP_NAME. Click on Create.

Step 4: Here you can see three options are there. We want to create Data Element hence click on data
element and Press Enter.
Step 5: Enter short description. Now we will give data type through domain.

For that we have to create domain.

Enter domain name. Here I entered ZAK_DM_EMP_NAME. Double click on the domain name.

Step 6: It will ask you to save. Save it


Step 7: It will ask you to create domain. Click on Yes.

Step 8: Enter short description. Enter data type as CHAR and number of characters 25.
Step 9: Save and activate it. And click on back. You will get below screen. Here domain is created.

Step 10: Now enter field label. And save it and activate it.
Here Data element is created.

Step 11: Go to SE11. And select database table and enter database table name which is created earlier and
click on change.

Step 12: Enter field name as Employee_name you can give any name and enter data element name which
is created earlier. Press enter.

Here we have created the domain.

Step 6: Go to SE11. Click on database table and open the table ZAKtable which is created earlier.
Step 7: Enter field name as Gender. Enter data element name ZAK_DE_GENDER.

Double click on data element name. It will ask you to save this and create data element.

Create data element.

Step 8: Give short description and enter domain name which is created ZAK_DM_GENDER.
Step 9: Give Field label, save it and activate it.

Here Data Element is created.

What is Value table?


Value table is created at domain level and use to give F4 help for all the fields which are referring to that
domain.

How to use Value Table


Step 1: Add field Blood_group in the table. Create Data element as ZAK_DE_B_GROUP.

Create Domain ZAK_DM_B_GROUP.

Step 2: Give Data Type CHAR and No Characters as 3.


Step 3: Click on Value Range.

Give the fixed values as we are creating domain for blood group.

Fixed values are O+, O-…etc.

Step 4: Give the value table name same name where we are using this domain.
Step 5: Save And Activate it. Also, activate data element.

Step 6: Go back. Click on Technical Settings.


Step 7: Select Data Class category as APPL0 means transparent table contains master data which change
rarely.

Select size category as 0.

Size category means number of records that can be store in database.

Step 8: Save it. Go back. Click on Extras.

Step 9: Select Enhancement Category.


Step 10: Select Can be enhance (character-like or numeric). Click on Copy.

Step 11: Save and activate the table.


This is how we create the table.

We have used value table for blood group we will see the search help for blood group field.

Click on Contents.

Here you can see that search symbol just beside the blood_group field. It is there because we have given
value table.

Click on search icon.


We can see that F4 help is created for Blood Group.

You might also like