HOW MANY WAYS TO DEFINE INTERNAL TABLES.
Answers were Sorted based on User's Feedback
Answer / girish m
there r so many ways to define internal table
1. data: begin of itab occurs 100,
matnr like mara-matnr,
mtart like mara-mtart,
end of itab.
2.data: begin of itab.
include mara.
data: end of itab.
3. data: begin of itab.
matnr like mara-matnr,
mtart like mara-mtart,
end of itab.
data: jtab type standard table itab,
gtab type itab.
4. data: itab like standard table of mara.
data: jtab like table itab.
5. data: itab like table of mara with header line.
Is This Answer Correct ? | 24 Yes | 10 No |
Basically there are 3 methods of creating the internal table which are used frequently, are as following:
1) for ex.
data: it_mara type table of mara.
note: after type table of, always a structure is used.
hence, here we call it structure mara not table mara.
and one thing more, here we can use like table of . but
it is not recommend. it is mostly used method.
2) for ex.
data: it_mara type mara occurs 0.
it means it_mara is a internal table of type mara.if we
write:
data: it_mara type mara occurs o with headerline.
it means there will be a internal table and a workarea
with the same name i.e. it_mara. hence it will little
confusing.
3) tables mara.
data: it_mara like mara occurs 0.
here, with the help of first statement, a workarea will be created with the name of mara and second statement will crate internal table with the name of it_mara. This is also little confusing because we mara is also of database table name and here it is also name of work area.
for exe.
select *
from mara
into mara.
hence, first method is most suitable and it should be used.
Is This Answer Correct ? | 4 Yes | 0 No |
Answer / krishna
data:itab type standard table of strcture name with header line.
data: itab1 type strcture name.
Is This Answer Correct ? | 2 Yes | 1 No |
What does an exec sql statement do in abap?
variant attached in the report. can be transportable from one server to another server
What is an “on input filed” statements?
What is the significance of the screen number ‘0’?
Explain the difference between float and packed data type?
What is synchronous update?
how to combine the transparent table with cluster table.
What are IDOCs?
where do we store all custom programs in SD module?
1 Answers Baidu, Thomson Reuters,
what is diffrence subroutine in report and subroutine in script.....
Differentiate between report and dialog program
Explain the sequences of event block?