Application Development 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: 

what is diffrence between like and type

Former Member
0 Kudos
212

Hi all,

Can any one tell me the difference between the type and like.

lets take i have a structure or table of some material data(MARA).

what is the difference between these two statements.

data wa like MARA.

data wa type mara.

please help me in this matter ,i was little bit confused.

1 ACCEPTED SOLUTION

Former Member
0 Kudos
69

Hi Narayna,

Take a look in this thread:

Regards,

Ville

3 REPLIES 3

Former Member
0 Kudos
70

Hi Narayna,

Take a look in this thread:

Regards,

Ville

Former Member
0 Kudos
69

Hi,

These statements are the same, because MARA is DDIC table. LIKE is not recommended to be used any more if TYPE can be used. LIKE can not be used in ABAP Objects.

Svetlin

0 Kudos
69

Hi,

TYPE is a keyword to refer data type.

LIKE is a keyword to refer data object.

data types are purely descriptive means no memory allocation.

data objects have memory allocation.

data types will define technical properties data objects.

hope this helps

regards,

sai chand