Include structure in smartform
I am trying to define types in smartform Global->Types.
1---types: BEGIN OF tvbdpr1.
INCLUDE STRUCURE vbdpr.----
vbdpr is view
types: END OF tvbdpr1.
it gives error:
"." or "IF FOUND." expected after "STRUCURE".
BUT when i define below there is no error
types: BEGIN OF tkomv1.
INCLUDE STRUCTURE komv.-------it is table
types: END OF tkomv1.
any help thanks
ismail
It was spelling error, thanks
Similar Messages
-
What is diff b/w Include Structure and Append Structure at Database Level
Hi Experts,
Could you please let me know what is the main difference between .Include Structure and .Append Structure at SE11?
Thanks in advance and for good answer will give good points.
SekharHi,
1. Append Structures
Append structures can only be assigned to a single table.
Append structures are created in the custome rnamespace ( ZZ or YY)
In case of new versions of the standard table during upgrade, the append structures are automatically appended to the new version of the standard table
Append structures can not be used with cluster and pool tables
Append structures are created in transaction SE11. Display the standard table fields and press the Append structure button.
When you press the button, SAP sugests a name for the new append structure. After you has accepted the name,
a screen will be shown where you can enter the new fields.
Remember to activate.
2. Customizing Includes
Some of the SAP standard tables contains special include statements called Customizing includes. In contrast to Append structures,
Note that customizing includes are created by SAP, but the customer supply the fields for the include.
Customizing includes begin with CI_ and is part of the customer namespace
One Customizing include can be inserted into more than one table.
You can find Customizing includes in SE11 under structures.
Try to take a look at table RKPF which uses the Customizing include CI_COBL (In an IDES system). Next try to add a field to CI_COBL, and activate it. If you go back to table RKPF you will se that your new field has been added.
Regards,
Ferry Lianto -
In a server proxy how can I use a INCLUDE STRUCTURE?
Hi people!!, how can I put an internal table with an INCLUDE statement in a server proxy in abap. If I put the next code the system present me this error: Within classes and interfaces, you can only use "TYPE" to refer to ABAP , Dictionary types, not "LIKE" or "STRUCTURE".
The problem is that I need the STRUCTURE to make a APPEND.
Thanks for the help.
DATA: BEGIN OF bdc_tab .
INCLUDE STRUCTURE bdcdata.
DATA: END OF bdc_tab.Hi Carlos,
Yes. It mainly accepts TYPE statements.
You can use this as:
DATA: BDC_LINE type bdcdata.
DATA: BDC_TAB type table of bdcdata.
When you want to use,
Fill the BDC_LINE.
Then:
Append BDC_LINE to BDC_TAB.
Or:
Loop at BDC_TAB into BDC_LINE.
Cheers,
Bhanu -
Extended syntax check for include structure
Hello Everyone,
While declaring the internal table as:
TYPES: BEGIN OF t_data.
INCLUDE STRUCTURE mara.
TYPES: END OF t_data.
DATA: it_data TYPE table of t_data.
When performing extended check, i get following error:
The current ABAP command is obsolete and problematic, especially so in ABAP
Objects
Within classes and interfaces, you can only use "TYPE" to refer to ABAP Dictionary
types, not "LIKE" or "STRUCTURE".
I am using 4.7 version.
Any clue how to avoid this error during extended check.
Regards,
TarunTarun,
With WAS 6.20 you should not declare internal tables with header line or using the old syntax as they are not compatible with OO ABAP.
So, you either declare a TYPE the way you have done, in case you want additional fields apart from the INCLUDE structure, or declare the table directly like the way I have shown.
Good thing, you can even specify the type of internal table that you want to create using this - STANDARD, SORTED, HASH. These tables will help you with the performance issues.
regards,
Ravi
Note : Please mark the helpful answers -
How to call structure in Smartforms
Hi,
For single table in Smartforms,we will do...
1)In form Interface,
Parameter_name Type_assignment Associated_type
itab like vbak
2)In Main window ->Table->Data
Loop...
Operand....itab into itab...
3)In Main Area->Row->Text
&itab-vbeln& &itab-ernam&....
It is working well in Abap editor by calling function module...
For Multiple Table fields,How to do in smartforms?
vbak-vbeln,vbap-posnr,kna1-kunnr....
suppose i create one structure....
data : begin of jtab occurs 0,
vbeln like vbak-vbeln,
posnr like vbap-posnr,
kunnr like kna1-kunnr,
end of jtab.
where i will have to call this structure in Smartforms...
In Global Definitions, How to configure this structure...Hi
Define one table type with these fields, and use this table type when declaring Form interface data in smartform.
REF:
You can create that structure in SE11
extras ---> change table category -->> select structure radio button
Reward if useful
Thanks
Krushna -
How do I Make Include Structures Expand Automatically?
As usual some of the simplest things take the longest time.
I've created a custom structure in the dictionary. I've also created a custom table in which I include the structure. I expected that after I added the include structure to the custom table, that it would be expanded and display in se11, and behave just as SAP-delivered tables do. For example, look at table PA0001. There are include lines followed by the contents of the include.
In my custom table though, I only see the include line itself. To see the structure I must expand it by pressing the expand button. Each and every time I display the custom table I must manually expand it. I want the behavior I see on every other SAP table.
Any ideas?
Thank you.
TomHi,
if You have include structure in Your table, all fields are displayed only in display mode.
That is the way You see the PA0001 table.
If You create your own table and include structure, in edit mode You can change fields of the include structure,
that is why it is not expanded. But if You change from edit to display mode, SAP does not expand it automatically.
You should display in SE11 this table - all fields will be visible.
Regards,
Przemysław -
How to include structure in Types Definition ???
Hello All,
I want a declaration like this in BSP :-
DATA : BEGIN OF imkop OCCURS 100.
INCLUDE STRUCTURE mkop.
DATA : waers LIKE mepro-waers.
DATA : END OF imkop.
<b>In BSP: Type Definitions</b>
I wrote like this :-
Types : BEGIN OF imkop.
INCLUDE STRUCTURE mkop.
Types : waers type mepro-waers.
Types : END OF imkop.
I'm getting an error saying that I can't use structures in this .
Now what should I do ?
Can anyone help me out ?
Regards,
Deepu.Kdeepu,
we can declare structures as below.
DATA: event_data TYPE REF TO cl_htmlb_event.
TYPES: BEGIN OF row_iid_type,
row_iid TYPE hap_row_iid,
END OF row_iid_type.
DATA:
t_row TYPE STANDARD TABLE OF row_iid_type,
t_row_wa TYPE row_iid_type,
t_message TYPE STANDARD TABLE OF bal_s_msg .
DATA:
lw_body_element TYPE hap_s_body_elements,
lw_body_column TYPE hap_s_body_columns,
lw_body_cell TYPE hap_s_body_cells,
lw_return TYPE bal_s_msg,
warning TYPE i.
regards,
manasa -
Selection-screen (field from .Include structure)
Hi all,
I have a selection screen with several select-options. One of the select-option is
select-options: s_vornr for afvc-vornr.
Where 'vornr' is a .Include structure field in the table 'afvc'. Now my question is, in selection screen when I click on the box for this particular select-option I dont see the circle(from where we can select the existing input values) at the end of the box.
Why is it so and how can get that circle option at the end of the box by sticking to the same table and field(afvc-vornr).
Waiting for your help.
Thankshi,
the field do not have nay value range with it.
you can put the F4 help by using
At Selection-Screen on Value-request <select-option>. event.
e.g.
DATA : rt_values TYPE STANDARD TABLE OF type_values,
rs_values TYPE type_values,
rt_fields TYPE STANDARD TABLE OF type_fields,
rs_fields TYPE type_fields.
CLEAR : rs_values,rs_fields.
REFRESH : rt_values,rt_fields.
Creation of selection list
rs_fields-tabname = 'AFVC'.
rs_fields-fieldname = 'VORNR
rs_fields-selectflag = ' '.
APPEND rs_fields TO rt_fields.
SELECT vornr form AFVC
INTO TABLE t_vornr.
SORT t_vornr.
DELETE ADJACENT DUPLICATES FROM t_vornr.
LOOP AT t_vornr INTO s_vornr.
rs_values = s_vornr-vornr.
APPEND rs_values TO rt_values.
CLEAR rs_values.
ENDLOOP.
FUNCTION 'HELP_VALUES_GET_WITH_TABLE' EXPORTING
fieldname = 'AFVC'
tabname = 'VORNR
titel = 'Counting
IMPORTING
select_value = <select-opion>
TABLES
fields = rt_fields
valuetab = rt_values.
amit
Message was edited by: Amit Khare -
Infotype and Include Structures in HR - ECC50
Hi,
I would like to know what are the changes in each and every infotype like different include structures or added fields or modified or deleted fields. How do you compare 46C version with ECC50.
Is there any way apart from remote version management option?
Thanks,
Kiran.Hi,
I don't know what your actual requirement is.. but the event GET PAYROLL already exists. PL take a look at the Program EXAMPLE_PNP_GET_PAYROLL to get an idea. You can also see the same at this <a href="http://help.sap.com/saphelp_47x200/helpdata/en/33/62ac39d22d11d396e700a0c9306433/frameset.htm">SAP help</a>
Regards,
Suresh Datti -
Problem with primary/secondary keys in table with included structures
Dear ABAPers,
we have a structure which is supposed to be included in the definition of several tables.
The problem is the following:
depending on the application table that includes this structure, 3 or 4 fields of that structure may
or may not be necessary to enhance the table key. As far as I know included structures can only
completely be marked as keys. Therefore I suggested to split up the structure into two parts,
one part with the possible candidates that may become key fields, and the rest, and of course
a structure that unites both of these substructures. So when it comes to reusing this structure
the developer would have the choice to select the structure with all of the fields in case no field
is needed as additional key, or the developer would have to implement both of the substructures
separately with the option to mark the key-part of it as key in his table.
But unfortunetaly this suggestion of mine was refused as being too complicated and I am supposed
to define all the fields in one flat structure and to "enhance" the primary keys (that always will exist)
by secondary keys.
Does anybody know how that is supposed to work without defining double indexes?
I cannot activate a table without having primary keys defined and any unique secondary index would
allways include all of the primary keys.
Thanks in advance for you help
(I'm sorry that you cannot be granted reward points for just reading the extensive problem description)
regards
AndreasDear Rob,
since your answer was helpful and since it was the only one I will grant you full points on that.
Thanks again for your input. In case other developers should look this thread up being confronted
with the same kind of problem, here is how we solved it:
We added an artificial primary key (a number of type NUMC 8) to the table which is supposed to
include the structure. This key alone takes care of the uniqueness of eacht entry.
All the others fields that we want to have available for a fast direct access, including the ones
from the included structure, are put together in a secondary index.
best regards
Andreas -
Include structure and extra fields in the same Internal Table
Hi developers,
im trying to declare an internal table with include structure and extra fields,
something like this:
data: BEGIN OF it_loans occurs 0,
include structure zthrca006,
status(10),
pernr like pa0001-pernr,
sname like pa0001-pernr,
tipomov(20),
monto like zthrca006-monto,
data: END of it_loans.
zthrca006 is huge so i dont want to type everithing.What is the issue?
data: BEGIN OF it_loans occurs 0.
include structure zthrca006.
data : status(10),
data : pernr like pa0001-pernr.
data : sname like pa0001-pernr.
data : tipomov(20).
data : monto like zthrca006-monto,.
data: END of it_loans.
Regards,
Ravi
Note - Please mark all the helpful answers -
Error on extended check for types include structure statements
Hi All ,
On Extended check im getting error :
Program: ZFIR_VALUATE_OBSOLETE_STOCK Include: ZFIR_VALUATE_OBSOLETE_STOCK_F Row: 1205
The current ABAP command is obsolete
Within classes and interfaces, you can only use "TYPE" to refer to ABAP Dictionary
types, not "LIKE" or "STRUCTURE".
Internal Message Code: MESSAGE G/B
(The message cannot be hidden using pseudo-comment "#EC .., bzw. durch SET
EXTENDED CHECK OFF/ON)
The error is in below line :
TYPES: BEGIN OF t_fttax.
INCLUDE STRUCTURE fttax.
TYPES: END OF t_fttax.
and fttax is a dictionary strucuture . i made internal table and work area using it .
DATA: i_fttax TYPE STANDARD TABLE OF t_fttax,
wa_fttax TYPE t_fttax.
Need Help ,what i should do to remove this error ?
Regardsdeclare as :
DATA: i_fttax TYPE STANDARD TABLE OF fttax,
wa_fttax TYPE fttax.
No need to declare as :
TYPES: BEGIN OF t_fttax.
INCLUDE STRUCTURE fttax.
TYPES: END OF t_fttax. -
Hi all
I have this code to give dynamic table name in select statement.
Is there a way the include structure tak in the value from my parameter value like name1?
DATA <b>name1</b>(10) TYPE c VALUE 'ZSTUDGARY'.
DATA: BEGIN OF wa OCCURS 0.
INCLUDE STRUCTURE <b>ZSTUDGARY</b>.
DATA: END OF wa.
SELECT *
INTO wa
FROM (name1) CLIENT SPECIFIED.
WRITE: / wa-eyear, wa-contact.
ENDSELECT.I think you are looking for somethign like this. Please check this code
REPORT ztest_gopi_dynamic.
TYPE-POOLS : abap.
FIELD-SYMBOLS: <dyn_table> TYPE STANDARD TABLE,
<dyn_wa>,
<dyn_field>.
DATA: dy_table TYPE REF TO data,
dy_line TYPE REF TO data,
xfc TYPE lvc_s_fcat,
ifc TYPE lvc_t_fcat.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME.
PARAMETERS: p_table(30) TYPE c DEFAULT 'T001'.
SELECTION-SCREEN END OF BLOCK b1.
START-OF-SELECTION.
PERFORM get_structure.
PERFORM create_dynamic_itab.
PERFORM get_data.
PERFORM write_out.
* FORM get_structure *
FORM get_structure.
DATA : idetails TYPE abap_compdescr_tab,
xdetails TYPE abap_compdescr.
DATA : ref_table_des TYPE REF TO cl_abap_structdescr.
* Get the structure of the table.
ref_table_des ?=
cl_abap_typedescr=>describe_by_name( p_table ).
idetails[] = ref_table_des->components[].
LOOP AT idetails INTO xdetails.
CLEAR xfc.
xfc-fieldname = xdetails-name .
xfc-datatype = xdetails-type_kind.
xfc-inttype = xdetails-type_kind.
xfc-intlen = xdetails-length.
xfc-decimals = xdetails-decimals.
APPEND xfc TO ifc.
ENDLOOP.
ENDFORM.
* FORM create_dynamic_itab *
FORM create_dynamic_itab.
* Create dynamic internal table and assign to FS
CALL METHOD cl_alv_table_create=>create_dynamic_table
EXPORTING
it_fieldcatalog = ifc
IMPORTING
ep_table = dy_table.
ASSIGN dy_table->* TO <dyn_table>.
* Create dynamic work area and assign to FS
CREATE DATA dy_line LIKE LINE OF <dyn_table>.
ASSIGN dy_line->* TO <dyn_wa>.
ENDFORM.
* FORM get_data *
FORM get_data.
* Select Data from table.
SELECT * INTO TABLE <dyn_table>
FROM (p_table).
ENDFORM.
* FORM write_out *
FORM write_out.
* Write out data from table.
LOOP AT <dyn_table> INTO <dyn_wa>.
DO.
ASSIGN COMPONENT sy-index
OF STRUCTURE <dyn_wa> TO <dyn_field>.
IF sy-subrc <> 0.
EXIT.
ENDIF.
IF sy-index = 1.
WRITE:/ <dyn_field>.
ELSE.
WRITE: <dyn_field>.
ENDIF.
ENDDO.
ENDLOOP.
ENDFORM.
Regards
Gopi -
Hi,
I'm trying to compile simple construction in ECC 60:
types: begin of t_bbseg.
include structure bbseg.
types: end of t_bbseg.
I have compilation error:
"The type "SI_BBSEG" is unknown"
Is anyone had something like this before?
We are NetWeaver 2004S Unicode enabled.
Thank you,
IharIf you are trying to include BSEG as a structure in the TYPE, use the TYPE keyword instead
types: begin of t_bbseg.
include type bseg.
types: end of t_bbseg.
REgards,
Rich Heilman -
Include structure in TYPES declaration
Hello All:
Many forum posts have discussed similar topics, but I couldn't exactly find one answering my requirement. Apologies if I have missed out reading some.
Instead of creating a type as below (as suggested in few forum posts)
TYPES begin of types ty_itab
include type BISEG
xxxx type xxx
xxxx type xxx
End of types ty_itab
I need to create the type with include structure after the additonal fields.
TYPES begin of types ty_itab
<fld1> type <ty1>
<fld2> type <ty2>
include type <struc>
End of types ty_itab
Can someone give the right syntax?
Please help,
Fred.Hello Fred
If you are using the extended syntax you should not encounter any problems:
TYPES: begin of types ty_itab.
TYPES: <fld1> type <ty1>.
TYPES: <fld2> type <ty2>.
include type <struc>.
TYPES: End of types ty_itab
Regards
Uwe
Maybe you are looking for
-
I want a 'date', on front page, to be reflected on all my headers automatically.
I have a document which has a date which is changed manually with every revision. Now I want that date to be reflected on headers automatically without manually editing header every time.
-
Where can I download Technical Communications Suite?
The company I work for has purchased Adobe TCS 3.5 and TCS 4, which were not bought through my Adobe ID (hence I cannot download them from the recent orders section). TCS 3.5 was registered to me as shown in my profile, but I cannot find any option t
-
Move or write to not doing conversion routine
I have two types of a file structure TYPES: BEGIN OF ty_est_archivo, mandt TYPE mandt, bukrs TYPE bukrs, gjahr TYPE gjahr, monat TYPE monat, xblnr(20), nacem(16), ctasc(10), transact_number TYPE cjtransnumb, transact_name(30), mwskz TYPE mwskz, cbase
-
Can't download purchased tv shows to original iPad
Cant download purchased tv shows to original iPad. Sitting in download queue but won't download.
-
Can't send yahoo or godaddy email
I use the Apple Mail client to view email accounts from yahoo and godaddy. I can receive mail on both accounts, but can suddenly send mail on neither account. It worked fine up until yesterday and I changed nothing! Pls help. I'm running OS 10.6.8