‎2008 Jun 13 7:24 AM
hi gurus,
the structure does not contain any data.... so i have 2 problem related to it.
1. do i apply the select query nd write statement on structure rf05l. i apply it gives error that rf05l is not the table.....
2. so what is the use of include structure in report, why we used it nd what is the procedure to read data from structure.
types : BEGIN OF t_rf05l.
include structure rf05l.
types : END OF t_rf05l.
DATA : it_rf05l TYPE STANDARD TABLE OF t_rf05l WITH HEADER LINE,
wa_it_rf05l TYPE t_rf05l.
select * from rf05l into it_rf05l.
append it_rf05l.
write :......
reply me soon....
thanx
manish sharma.
‎2008 Jun 13 7:39 AM
Hi,
-- SELECT statement should be used only on database tables like, MARA, MARC etc...--
The example given by you is an internal table, but not database table.
Use below logic
select * from rf051 into table it_rf051.
Loop at it_rf051.
Write: ......
endloop.
Include strucute , includes the fields of a structure into the internal table. i.e., no need to define each field individually.
Edited by: Ramesh Hirial on Jun 13, 2008 3:42 PM
‎2008 Jun 13 7:35 AM
Hi
select * from rf05l into it_rf05l.
append it_rf05l.
write :......
Do this:
select * from rt05l
into corresponding fields of table it_r05l.
loop at it_ro5l into wa_it_rf05l.
write....
endloop.
include structure rf05l. mens you are including all the fields of that Database table into itab or your structure. its does not mean that rt05l can be used as ITAB.
Regards
Aditya
‎2008 Jun 13 7:40 AM
hi guru,
it has given same problem that rf05l is not a dicitionary table or view.
‎2008 Jun 13 7:52 AM
Hi Manish,
First u know what is difference between the table and structure.
Table has data and structure dosent has data.
In select querie write the DB table name and into ur structure.
hence it is throwing error.
Select * from table <DB talbe > into table it_rf051 where
condition.
regards,
‎2008 Jun 13 7:39 AM
Hi,
-- SELECT statement should be used only on database tables like, MARA, MARC etc...--
The example given by you is an internal table, but not database table.
Use below logic
select * from rf051 into table it_rf051.
Loop at it_rf051.
Write: ......
endloop.
Include strucute , includes the fields of a structure into the internal table. i.e., no need to define each field individually.
Edited by: Ramesh Hirial on Jun 13, 2008 3:42 PM
‎2008 Jun 13 7:40 AM
Hi Manish,
INCLUDE STRUCTURE is only used to declare the Internal table structure , structures do not hold any data
Check the relevent TRANSPARENT table for that structure and use SELECT for that table