‎2007 Sep 06 9:44 AM
Hi expert ,
we are trying to understand the following example.
SF_EXAMPLE_01 .
IT has declared in form interface :
bookings type ty_bookings.
connection type ty_connections.
now i m not getting wat is ty_connections and ty_booking.
thanks ,
ashish
‎2007 Sep 06 9:49 AM
Hi,
Ty_conncetions is a type which declare in type tab of global declaration .Then make table type of this user defined type and then in blobal data tab declare internal table and workarea type of this table and type accordingly.
Rewards points if it is useful.
‎2007 Sep 06 9:50 AM
Hi,
these are declared in the global delcarations
types tab
chek out there
some eg:
types: being of ty_mara.
matnr type mara-matnr,
ersda type mara-ersda,
end of ty-mara.
types: t_it_mara type standard table of ty_mara.
data: it_mara type t_it_mara. " willl be the body
data: wa_mara type ty_mara . " will be the work area
so in your case
ty_bookings will be the reference structure
thanks & regards,
Venkatesh
‎2007 Sep 06 9:51 AM
hI,
THESE ARE GLOBAL TYPES....YOU CAN CHECK THESE IN SE11.
OR JUST DOUBLE CLICK ON THOSE ...IT WILL REDIRECT YOU TO THE POINT WHERE IT HAS BEEN DEFINES...YOU WILL GET TO KNOW ALL THE THINKGS ABOUT THESE..
THANKS
VIVEKANAND
‎2007 Sep 06 9:57 AM
please go to the smart form and type the form name.
go inside and look to the place where the declaration TY_BOOKINGS has been done.
double click into it.
it will take u to the SE11 and display the structre of this particular variable.
it represent the table type for table sbook and the other one is for Flight schedule.
REWARD ME THE MAX. POINT IF HAPPY WITH THE ANSWER.
‎2007 Sep 06 10:06 AM
Hi prakash,
That TY_BOOKINGS and TY_CONNECTIONS are table types which are available in DDIC level. This table types holds either structure or table name. This ty_bookings has line type SBOOK and ty_connections has line type SPFLI.
If you refer this table type you can implicit internal table with header. if you refer the structure or table name only workarea will created.
BOOKING type TY_BOOKINGS
CONNECTIONS type TY_CONNECTIONS
Is same as
BOOKING type standard table of sbook
CONNECTIONS type standard table of spfli (this will work in global definitions)
I hope this make it clear to you.
<i><b>Don't forgot to Reward points,Which boost us to help others</b></i>
All the best.....
Regards
Sreenivasa sharma
‎2007 Sep 06 10:06 AM
Hi Prakash,
I think you are practicing Smartforms...
I hope you know that smartform generates a function module when we activate it.
And we will call this function module in our program.. and pass the data from the program to smartfrom...
<b>U know how to pass tables to Function module..</b>
1) If the table is having structure defined in the dictionary ... then directly throught the tables tab of the function module.. ( t_spfli like spfli ).. here SPFLI exist in dictionary as a table..
2) if you want to send 3 more fields along with spfli structure.. then you can pass directly through the tables Parameter !! for this first you have to create a TABLE TYPE in dictionary with all the fields that you want ... and then pass the table which is having extra 3 fields to the smartform....
here<b> ty_bookings</b> is a table type.. which is used to send data to Smartform !!!
Now try to test one thing..
You have SPFLI in your dictionary right !!
Now go to a program and define like this..
DATA : T_SPFLI TYPE SPLI.
DATA : T_BOOKINGS TYPE TY_BOOKINGS.
Here t_spfli is a work area ( Structure ).., but t_bookings is a table !!!!
Hope u understood !!
<b>Please do remember to close the thread when ur problem is solved !!</b>
Regards,
Sai Ramesh