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

basic

Former Member
0 Likes
621

Hi friend,

anybody will tell me what is the diff. b/w

types: begin of ts_data,

................

...............

end of ts_data.

and

data: begin of ts_data,

................

...............

end of ts_data.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
595

Hi,

Types is used to define your customised type.

You can then create data structures or tables giving simply the type defination.

However,

Data is used to create data type which can directly be assigned a value.

Hope that helps.

Regards,

Tanveer.

<b>Please mark helpful answers</b>

4 REPLIES 4
Read only

Former Member
0 Likes
595

Types stmnt define type .its like creating a type. It doesn't create any data object.you can create data objects of this types once defined , by using data stmnt.

DATA stmnt create a data object which can able to hold data.

Read only

Former Member
0 Likes
595

Hi Salil,

The first format is for creating a structure and the second format is used for creating an internal table without header line.

Read only

dani_mn
Active Contributor
0 Likes
595

Hi,

TYPES: system didn't allocate any memory for this. this is a data type and will be used to reference any data declaration.

TYPES: begin of itab_type
       abc(10),
       end of itab_type.

data: itab_actual type itab_type.

DATA: declares actual data and system allocate memory for this variable.

Regards,

Wasim Ahmed

Read only

Former Member
0 Likes
596

Hi,

Types is used to define your customised type.

You can then create data structures or tables giving simply the type defination.

However,

Data is used to create data type which can directly be assigned a value.

Hope that helps.

Regards,

Tanveer.

<b>Please mark helpful answers</b>