Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

what is table type

Former Member
0 Likes
944

what is table type and line type and how both are related

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
895

Hi

As the name suggests, line type will create data for storing only one record or like structure and table type is for creating a table for the structure mentioned.

Regards

Navneet

6 REPLIES 6
Read only

Former Member
0 Likes
896

Hi

As the name suggests, line type will create data for storing only one record or like structure and table type is for creating a table for the structure mentioned.

Regards

Navneet

Read only

abdulazeez12
Active Contributor
0 Likes
895

Usually when you create a table, you add all the fields you need.

A table type is based on a structure. Instead of adding fields, you just add one structure. Very useful sometimes. Especially in OO.

The transaction is just SE11. When you select create, you can choose 'Table type'. Then you enter a structure in the row type.

If you are declaring any STRUCTURE on your program, then we can represent those as

TYPE linetype

.

This would make the data declaration more understandable.

Please refer below link :

http://help.sap.com/saphelp_nw04/helpdata/en/0b/e06b1c2d8411d5b693006094192fe3/frameset.htm

Read only

Former Member
0 Likes
895

HI,

line type will act as a structure(wa).we can store only one reocrd.

table table will act as an internal table without header line.

rgds,

bharat.

Read only

ferry_lianto
Active Contributor
0 Likes
895

Hi,

Table type is used to declare an internal table.

Line type is used to create work area for an internal table.

Example:


data: begin of ty_mara,
        matnr like mara-matnr,
        werks like marc-werks,
        maktx like makt-maktx,
end of ty_mara.

Data: it_mara type table of ty_mara.

Data: wa_mara like line of it_mara.

Here you are creating an internal table it_mara of type ty_mara. For work area you are creating a structure wa_mara which looks like a line of it_mara with same fields.

Regards,

Ferry Lianto

Read only

Former Member
0 Likes
895

A table type is a type that describes the structure and functions of an

internal table in the ABAP program.

It describes the following attributes of an internal table:

1- Row type,

2- Key definition,

3- Key category,

4- Access Mode.

It is also very useful in defining internal tables, that need to be exported to the Smartforms in the form Interface.