Table maintanence generator Events and BADI
hi,
We are in middle of creating technical design. The scenario is given below.
A BADI is implemented and the we are writing code for saving data in a table and we are writing events in table maintanence generator for this table to validate the data before saving.
So if error occurs, we can't populate it as error message as this is done in between of BADI. So how to capture these error messages and give to BADI.
I am thinking to use EXPORT and IMPORT to memory. Will this work? Or is there any other method for this? I am not able to check in SAP as the client doesnt want to create anything before signing off the TD.
I answered the exact same question a few minutes back in another thread. Hope this works.
read table new entry
For the others who have answered this question:
I tried referencing the table directly and whenever i enter multiple entries the validations where failing. I could not do a loop at table. My validations were supposed to be triggered only at the time of saving the entries and not at the time of entry. Anybody has a workaround besides what i have described in the post??
Similar Messages
-
Table maintanence generator with events
Hi ,
I am having a custom table for which 2 new fields were added .
Now the data for the two fields shold be populated depending on conditions using table maintanence generator .
the two fields are : date and time.
for every existing and new record the date and time shold be populated once the action is taken plae using SM30.
can you please provide the sufficient info to achive the same .
which events to be used and how the code should be ...
thanksI answered the exact same question a few minutes back in another thread. Hope this works.
read table new entry
For the others who have answered this question:
I tried referencing the table directly and whenever i enter multiple entries the validations where failing. I could not do a loop at table. My validations were supposed to be triggered only at the time of saving the entries and not at the time of entry. Anybody has a workaround besides what i have described in the post?? -
Hi...
3....how to create table maintanence generator for a z table and how to use that for transfering a selected records to one server to another server.
thanks and regards,
k.swaminath reddyHi,
Table maintanance Generator is used to manually
input values using transaction sm30.The Table Maintenance Generator is used to create table maintenance program to add, modify or delete records in the database table. This can be accessed using transaction SE54 or in SE11 using the menu Utilities->Table Maintenance Generator
<b>
Follow below steps</b>
go to se11 check table maintanance check box under
attributes tab
utilities-table maintanance Generator->
create function group and assign it under
function group input box.
also assign authorization group default &NC& .
select standard recording routine radio in table
table mainitainence generator to move table
contents to quality and production by assigning
it to request.
select maintaience type as single step.
maintainence screen as system generated numbers
this dialog box appears when you click on create
button
save and activate table
http://help.sap.com/saphelp_nw04/helpdata/en/cf/21ed2d446011d189700000e8322d00/content.htm
One step, two step in Table Maintenance Generator
Single step: Only overview screen is created i.e. the Table Maintenance Program will have only one screen where you can add, delete or edit records.
Two step: Two screens namely the overview screen and Single screen are created. The user can see the key fields in the first screen and can further go on to edit further details.
please check the link for getting information about table maintenance generator !
https://www.sdn.sap.com/irj/sdn/advancedsearch?query=use%20of%20table%20maintenance%20generator&cat=sdn_all
http://www.sapdevelopment.co.uk/tips/tips_tabmaint_tcode.htm
http://www.sap-img.com/abap/create-a-table-maintance-program-for-a-z-table.htm
Regards,
Priyanka. -
Reg : Table Maintanence Generator
hi friends,
After creating a Z-Table,,we can create entries and diaplay the entries.
But then Why do we go for Table Maintanence Generator.
waiting for your answers
Reagrds
VajaHi,
With the help of the table maintenance generator, you are able to maintain the ENTRIES of the table in SM30 transaction.
It can be set in transaction SE11 - Tools - Table maintenance generator.
Table maintanance Generator is used to manually input values using transaction sm30
follow below steps
1) go to se11 check table maintanance check box under attributes tab
2) utilities-table maintanance Generator-> create function group and assign it under
function group input box. Also assign authorization group default &NC& .
3) select standard recording routine radio in table table mainitainence generator to move table
contents to quality and production by assigning it to request.
4) select maintaience type as single step.
5) maintainence screen as system generated numbers this dialog box appears when you click on create button
6) save and activate table
One step, two step in Table Maintenance Generator
Single step: Only overview screen is created i.e. the Table Maintenance Program will have only one screen where you can add, delete or edit records.
Two step: Two screens namely the overview screen and Single screen are created. The user can see the key fields in the first screen and can further go on to edit further details.
SM30 is used for table maintenance(addition or deletion of records),
For all the tables in SE11 for which Table maintenance is selected , they can be maintained in SM30
Sm30 is used to maintain the table ,i.e to delete ,insert or modify the field values and all..
It creates the maintenance screen for u for the aprticular table as the maintenance is not allowed for the table..
In the SE11 delivery and maintenance tab, keep the maintenance allowed..
Then come to the SM30 and then enter the table name and press maintain..,
Give the authorization group if necessary and give the function group and then select maintenance type as one step and give the screen numbers as system specified..
Then create,,,
Then u will able to see the maintenance view for the table in which u can able to insert and delete the table values...
We use SM30 transaction for entering values into any DB table.
First we create a table in SE11 and create the table maintenance generator for that Table using (utilities-> table maintenance generator) and create it.
Then it will create a View.
After that from SM30, enter the table name and Maintain, create new entries, change the existing entries for that table.
For further help look into these links
http://help.sap.com/saphelp_46c/helpdata/EN/cf/21eb6e446011d189700000e8322d00/frameset.htm
http://help.sap.com/saphelp_bw30b/helpdata/en/69/c2516e4ba111d189750000e8322d00/content.htm
Table
Hope this resolves your query.
Regards,
Omkar. -
Regarding Table maintanence generator
Hi,
I have a requirement were in i need to upload data in to this customisizing table using table maintanenece gen....My requirement is to hide the primary key which is of no use to end user instead when he enters data into this the i should generate the primary key by means of some FM which wud be unique for each record of the entry created in the table.....but the user should not see the first key which is primary key here in my case should be hidden in the table maintanence generator......Please response quickly its urgent...............
Thanking you in Advance......here is the code for that
REPORT ZTAB_MAINT
NO STANDARD PAGE HEADING
MESSAGE-ID ZZ.
* T Y P E D E C L A R A T I O N S
*--Types declaration for selection to be passed as parameter into
*--VIEW_MAINTENANCE_CALL FM
TYPES: BEGIN OF TP_RANGETAB.
INCLUDE STRUCTURE VIMSELLIST.
TYPES: END OF TP_RANGETAB.
* D A T A D E C L A R A T I O N S
DATA: V_MATNR TYPE MATNR, " Material Number
V_WERKS TYPE WERKS_D, " Plant
V_KONOB TYPE KONOB, " Product allocation object
V_ZCPLT(40) TYPE C. " Message
* I N T E R N A L T A B L E D E C L A R A T I O N S
* Internal table to subroutine code
*Internal table used as selection for VIEW_MAINTENANCE_CALL FM
DATA: IT_RANGETAB TYPE STANDARD TABLE OF TP_RANGETAB WITH HEADER LINE.
*--Internal table used for getting the tablefields
DATA: BEGIN OF IT_HEADER OCCURS 1.
INCLUDE STRUCTURE VIMDESC.
DATA: END OF IT_HEADER.
*--Name Tabel
DATA: BEGIN OF IT_NAMTAB OCCURS 50.
INCLUDE STRUCTURE VIMNAMTAB.
DATA: END OF IT_NAMTAB.
*--Used for handling 'BT' option
DATA: BEGIN OF IT_MATNR OCCURS 0,
MATNR TYPE MATNR,
END OF IT_MATNR.
*--Used for handling 'BT' option
DATA: BEGIN OF IT_WERKS OCCURS 0,
WERKS TYPE WERKS,
END OF IT_WERKS.
*--Used for handling 'BT' option
DATA: BEGIN OF IT_KONOB OCCURS 0,
KONOB TYPE KONOB,
END OF IT_KONOB.
*--Used for handling 'BT' option
DATA: BEGIN OF IT_ZCPLT OCCURS 0,
ZCPLT(40) TYPE C,
END OF IT_ZCPLT.
* I N P U T S C R E E N
SELECTION-SCREEN BEGIN OF BLOCK SELSCR WITH FRAME TITLE TEXT-001.
RANGES: R_MATNR FOR V_MATNR.
RANGES: R_WERKS FOR V_WERKS.
RANGES: R_KONOB FOR V_KONOB.
RANGES: R_ZCPLT FOR V_ZCPLT.
* Select Options
SELECT-OPTIONS: S_MATNR FOR V_MATNR NO-EXTENSION, " Material
S_WERKS FOR V_WERKS NO-EXTENSION, " Plant
S_KONOB FOR V_KONOB NO-EXTENSION,
" Product allocation object
S_ZCPLT FOR V_ZCPLT NO-EXTENSION. " Plant
SELECTION-SCREEN END OF BLOCK SELSCR.
* A T S E L E C T I O N S C R E E N
AT SELECTION-SCREEN.
* Validate user inputs
PERFORM FRM_VALIDATIONS.
* S T A R T O F S E L E C T I O N
START-OF-SELECTION.
* Fetch Data from Data Base
PERFORM FRM_GET_DATA.
* S U B R O U T I N E S
*& Form frm_get_data
* Call the function module VIEW_MAINTENNACE_CALL to get data
* based on selection criteria
FORM FRM_GET_DATA .
CALL FUNCTION 'VIEW_GET_DDIC_INFO'
EXPORTING
VIEWNAME = 'ZTAB'
TABLES
X_HEADER = IT_HEADER
X_NAMTAB = IT_NAMTAB
SELLIST = IT_RANGETAB
EXCEPTIONS
NO_TVDIR_ENTRY = 1
TABLE_NOT_FOUND = 2.
IF SY-SUBRC <> 0.
MESSAGE E002 WITH 'Error in ZTAB table'(005).
ENDIF.
CLEAR: IT_RANGETAB,
IT_RANGETAB[].
LOOP AT IT_NAMTAB.
CASE IT_NAMTAB-VIEWFIELD.
WHEN 'MATNR'.
CLEAR IT_RANGETAB.
IT_RANGETAB-VIEWFIELD = 'MATNR'.
IT_RANGETAB-TABIX = SY-TABIX.
IT_RANGETAB-DDIC = IT_NAMTAB-READONLY.
LOOP AT S_MATNR.
CASE S_MATNR-OPTION.
WHEN 'EQ'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'EQ'.
IT_RANGETAB-VALUE = S_MATNR-LOW.
APPEND IT_RANGETAB.
WHEN 'BT'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'GE'.
IT_RANGETAB-VALUE = S_MATNR-LOW.
APPEND IT_RANGETAB.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'LE'.
IT_RANGETAB-VALUE = S_MATNR-HIGH.
APPEND IT_RANGETAB.
WHEN 'NB'.
CLEAR: R_MATNR,
R_MATNR[].
R_MATNR-SIGN = 'I'.
R_MATNR-OPTION = 'BT'.
R_MATNR-LOW = S_MATNR-LOW.
R_MATNR-HIGH = S_MATNR-HIGH.
APPEND R_MATNR.
SELECT MATNR
INTO TABLE IT_MATNR
FROM ZTAB
WHERE MATNR IN R_MATNR.
DELETE ADJACENT DUPLICATES FROM IT_MATNR COMPARING MATNR
LOOP AT IT_MATNR.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'NE'.
IT_RANGETAB-VALUE = IT_MATNR-MATNR.
APPEND IT_RANGETAB.
ENDLOOP.
WHEN 'NE'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'NE'.
IT_RANGETAB-VALUE = S_MATNR-LOW.
APPEND IT_RANGETAB.
WHEN OTHERS.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = S_MATNR-OPTION.
IT_RANGETAB-VALUE = S_MATNR-LOW.
APPEND IT_RANGETAB.
ENDCASE.
ENDLOOP.
WHEN 'WERKS'.
CLEAR IT_RANGETAB.
IT_RANGETAB-VIEWFIELD = 'WERKS'.
IT_RANGETAB-TABIX = SY-TABIX.
IT_RANGETAB-DDIC = IT_NAMTAB-READONLY.
LOOP AT S_WERKS.
CASE S_WERKS-OPTION.
WHEN 'EQ'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'EQ'.
IT_RANGETAB-VALUE = S_WERKS-LOW.
APPEND IT_RANGETAB.
WHEN 'BT'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'GE'.
IT_RANGETAB-VALUE = S_WERKS-LOW.
APPEND IT_RANGETAB.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'LE'.
IT_RANGETAB-VALUE = S_WERKS-HIGH.
APPEND IT_RANGETAB.
WHEN 'NB'.
CLEAR: R_WERKS,
R_WERKS[].
R_WERKS-SIGN = 'I'.
R_WERKS-OPTION = 'BT'.
R_WERKS-LOW = S_WERKS-LOW.
R_WERKS-HIGH = S_WERKS-HIGH.
APPEND R_WERKS.
SELECT WERKS
INTO TABLE IT_WERKS
FROM MARC
WHERE WERKS IN R_WERKS.
DELETE ADJACENT DUPLICATES FROM IT_WERKS COMPARING WERKS
LOOP AT IT_WERKS.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'NE'.
IT_RANGETAB-VALUE = IT_WERKS-WERKS.
APPEND IT_RANGETAB.
ENDLOOP.
WHEN 'NE'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'NE'.
IT_RANGETAB-VALUE = S_WERKS-LOW.
APPEND IT_RANGETAB.
WHEN OTHERS.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = S_WERKS-OPTION.
IT_RANGETAB-VALUE = S_WERKS-LOW.
APPEND IT_RANGETAB.
ENDCASE.
ENDLOOP.
WHEN 'KONOB'.
CLEAR IT_RANGETAB.
IT_RANGETAB-VIEWFIELD = 'KONOB'.
IT_RANGETAB-TABIX = SY-TABIX.
IT_RANGETAB-DDIC = IT_NAMTAB-READONLY.
LOOP AT S_KONOB.
CASE S_KONOB-OPTION.
WHEN 'EQ'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'EQ'.
IT_RANGETAB-VALUE = S_KONOB-LOW.
APPEND IT_RANGETAB.
WHEN 'BT'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'GE'.
IT_RANGETAB-VALUE = S_KONOB-LOW.
APPEND IT_RANGETAB.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'LE'.
IT_RANGETAB-VALUE = S_KONOB-HIGH.
APPEND IT_RANGETAB.
WHEN 'NB'.
CLEAR: R_KONOB,
R_KONOB[].
R_KONOB-SIGN = 'I'.
R_KONOB-OPTION = 'BT'.
R_KONOB-LOW = S_KONOB-LOW.
R_KONOB-HIGH = S_KONOB-HIGH.
APPEND R_KONOB.
SELECT KONOB
INTO TABLE IT_KONOB
FROM T190
WHERE KONOB IN R_KONOB.
DELETE ADJACENT DUPLICATES FROM IT_KONOB COMPARING KONOB
LOOP AT IT_KONOB.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'NE'.
IT_RANGETAB-VALUE = IT_KONOB-KONOB.
APPEND IT_RANGETAB.
ENDLOOP.
WHEN 'NE'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'NE'.
IT_RANGETAB-VALUE = S_KONOB-LOW.
APPEND IT_RANGETAB.
WHEN OTHERS.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = S_KONOB-OPTION.
IT_RANGETAB-VALUE = S_KONOB-LOW.
APPEND IT_RANGETAB.
ENDCASE.
ENDLOOP.
WHEN 'ZCPLT'.
CLEAR IT_RANGETAB.
IT_RANGETAB-VIEWFIELD = 'ZCPLT'.
IT_RANGETAB-TABIX = SY-TABIX.
IT_RANGETAB-DDIC = IT_NAMTAB-READONLY.
LOOP AT S_ZCPLT.
CASE S_ZCPLT-OPTION.
WHEN 'EQ'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'EQ'.
IT_RANGETAB-VALUE = S_ZCPLT-LOW.
APPEND IT_RANGETAB.
WHEN 'BT'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'GE'.
IT_RANGETAB-VALUE = S_ZCPLT-LOW.
APPEND IT_RANGETAB.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'LE'.
IT_RANGETAB-VALUE = S_ZCPLT-HIGH.
APPEND IT_RANGETAB.
WHEN 'NB'.
CLEAR: R_ZCPLT,
R_ZCPLT[].
R_ZCPLT-SIGN = 'I'.
R_ZCPLT-OPTION = 'BT'.
R_ZCPLT-LOW = S_ZCPLT-LOW.
R_ZCPLT-HIGH = S_ZCPLT-HIGH.
APPEND R_ZCPLT.
SELECT ZCPLT
INTO TABLE IT_ZCPLT
FROM ZTAB
WHERE ZCPLT IN R_ZCPLT.
DELETE ADJACENT DUPLICATES FROM IT_ZCPLT COMPARING ZCPLT
LOOP AT IT_ZCPLT.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'NE'.
IT_RANGETAB-VALUE = IT_ZCPLT-ZCPLT.
APPEND IT_RANGETAB.
ENDLOOP.
WHEN 'NE'.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = 'NE'.
IT_RANGETAB-VALUE = S_ZCPLT-LOW.
APPEND IT_RANGETAB.
WHEN OTHERS.
IT_RANGETAB-AND_OR = 'AND'.
IT_RANGETAB-OPERATOR = S_ZCPLT-OPTION.
IT_RANGETAB-VALUE = S_ZCPLT-LOW.
APPEND IT_RANGETAB.
ENDCASE.
ENDLOOP.
ENDCASE.
ENDLOOP.
IF S_ZCPLT[] IS INITIAL.
CALL FUNCTION 'VIEW_MAINTENANCE_CALL'
EXPORTING
ACTION = 'U'
VIEW_NAME = 'ZTAB'
TABLES
DBA_SELLIST = IT_RANGETAB
EXCEPTIONS
CLIENT_REFERENCE = 1
FOREIGN_LOCK = 2
INVALID_ACTION = 3
NO_CLIENTINDEPENDENT_AUTH = 4
NO_DATABASE_FUNCTION = 5
NO_EDITOR_FUNCTION = 6
NO_SHOW_AUTH = 7
NO_TVDIR_ENTRY = 8
NO_UPD_AUTH = 9
ONLY_SHOW_ALLOWED = 10
SYSTEM_FAILURE = 11
UNKNOWN_FIELD_IN_DBA_SELLIST = 12
VIEW_NOT_FOUND = 13
MAINTENANCE_PROHIBITED = 14
OTHERS = 15.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ELSE.
CALL FUNCTION 'VIEW_MAINTENANCE_CALL'
EXPORTING
ACTION = 'U'
VIEW_NAME = 'ZTAB_ZTEST'
TABLES
DBA_SELLIST = IT_RANGETAB
EXCEPTIONS
CLIENT_REFERENCE = 1
FOREIGN_LOCK = 2
INVALID_ACTION = 3
NO_CLIENTINDEPENDENT_AUTH = 4
NO_DATABASE_FUNCTION = 5
NO_EDITOR_FUNCTION = 6
NO_SHOW_AUTH = 7
NO_TVDIR_ENTRY = 8
NO_UPD_AUTH = 9
ONLY_SHOW_ALLOWED = 10
SYSTEM_FAILURE = 11
UNKNOWN_FIELD_IN_DBA_SELLIST = 12
VIEW_NOT_FOUND = 13
MAINTENANCE_PROHIBITED = 14
OTHERS = 15.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDIF.
ENDFORM. " frm_get_data
*& Form frm_validations
* Validating field values
FORM FRM_VALIDATIONS .
* Material number should not be validated (10/17/2005)
CLEAR V_MATNR.
SELECT SINGLE MATNR
INTO V_MATNR
FROM MARA
WHERE MATNR IN S_MATNR.
IF SY-SUBRC <> 0.
MESSAGE E002 WITH 'Material not found'.
ENDIF.
CLEAR V_WERKS.
SELECT SINGLE WERKS
INTO V_WERKS
FROM ZTAB
WHERE WERKS IN S_WERKS.
IF SY-SUBRC <> 0.
MESSAGE E002 WITH 'Plant (WERKS) not found'(002).
ENDIF.
CLEAR V_KONOB.
SELECT SINGLE KONOB
INTO V_KONOB
FROM ZTAB
WHERE KONOB IN S_KONOB.
IF SY-SUBRC <> 0.
MESSAGE E002 WITH ' Product allocation object not found'(003).
ENDIF.
CLEAR V_WERKS.
SELECT SINGLE WERKS
INTO V_WERKS
FROM ZTAB
WHERE WERKS IN S_ZCPLT.
IF SY-SUBRC <> 0.
MESSAGE E002 WITH 'Plant (ZCPLT) not found'(004).
ENDIF.
ENDFORM. " frm_validations
reward points if it is usefull ...
Girish -
'Z' table maintanence generator
Hi,
I am having a 'Z' table with 7 fields. In this 'Z' table I also have a field whose data type is STRING, for which I've created a 'Z' data type and a 'Z' domain.
I am not able to create:
1) Maintainence view using Tale maintanence generator for this table.
Error is get is 'Data type STRING not supported in field SMS'.
2) Neither am I able to maintain/modify entries in table using SE16N and check maintain entries, even after changing attributes as 'Display/Maintenance Allowed'.
Even if I change some entries and click SAVE I get a dump saying
Runtime errors ASSIGN_CASTING_ILLEGAL_CAST
Exception CX_SY_ASSIGN_CAST_ILLEGAL_CAST
Occurred on 10.09.2009 at 11:34:41
Error in an ASSIGN ... CASTING statement in program "SAPLSE16N".
Is it because of my data elemene string or something else?
Please help.
Regards,
AmitHi Amit,
Yes. You are right. Table maintenance generator does not support fields of type with string, raw, rawstring, internal table, object reference etc...
One solution I think is to create a maintenance transaction on your own.
Regards,
Deepika. -
Table maintenance generator events
Hi,
I have created a table maintenance generator and want to populate sy-uname and sy-datum into two fields during SAVE. So I went to Environment -> Modification -> Events and selected "01" event i.e. "Before saving the data in the database" and entered Form routine as "F_UPDATE_UNAME_UDATE". Then if I go to SM30 transaction it goes to dump.
Could you please tell whether I am missing any point?
Regards,
Balaji Viswanath.Hi,
Pasted it below.
Runtime Error PERFORM_NOT_FOUND
Except. CX_SY_DYN_CALL_ILLEGAL_FORM
Date and Time 01/31/2008 09:26:52
ShrtText
Call (PERFORM) to a non-existent routine.
What happened?
The current program attempted to call an externally defined routine
that does not exist.
Error in ABAP application program.
The current ABAP program "SAPLZTEST321" had to be terminated because one of the
statements could not be executed.
This is probably due to an error in the ABAP program.
The current ABAP program had to be terminated because the
ABAP processor detected an internal system error.
The current ABAP program "SAPLZTEST321" had to be terminated because the ABAP
processor discovered an invalid system state.
What can you do?
Print out the error message (using the "Print" function)
and make a note of the actions and input that caused the
error.
To resolve the problem, contact your SAP system administrator.
You can use transaction ST22 (ABAP Dump Analysis) to view and administer
termination messages, especially those beyond their normal deletion
date.
is especially useful if you want to keep a particular message.
Error analysis
An exception occurred. This exception is dealt with in more detail below
. The exception, which is assigned to the class 'CX_SY_DYN_CALL_ILLEGAL_FORM',
was neither
caught nor passed along using a RAISING clause, in the procedure
"PREPARE_SAVING" "(FORM)"
Since the caller of the procedure could not have expected this exception
to occur, the running program was terminated.
The reason for the exception is:
The program "SAPLZTEST321" is meant to execute an external PERFORM,
namely the routine "F_UPDATE_UNAME_UDATE " of the program "SAPLZTEST321 ", but
this routine does not exist.
This may be due to any of the following reasons:
1. One of the programs "SAPLZTEST321" or "SAPLZTEST321 " is currently being
developed.
The name "F_UPDATE_UNAME_UDATE " of the called routine may be incorrect, or
the routine "F_UPDATE_UNAME_UDATE " is not yet implemented in the program
"SAPLZTEST321 ".
2. If the program SAPMSSY1 is involved in the runtime error, one of
the function modules called via RFC is not flagged as remote-capable.
(see Transaction SE37 Goto->Administration->RFC flag)
3. There is an inconsistency in the system. The versions of the
programs "SAPLZTEST321" and "SAPLZTEST321 " do not match.
How to correct the error
- Check that transports to the system are complete.
- Conclude any developments already begun ("SAPLZTEST321" and/or "SAPLZTEST321
- Check routine names
You may able to find an interim solution to the problem
in the SAP note system. If you have access to the note system yourself,
use the following search criteria:
"PERFORM_NOT_FOUND" CX_SY_DYN_CALL_ILLEGAL_FORMC
"SAPLZTEST321" or "LSVIMF14"
"PREPARE_SAVING"
If you cannot solve the problem yourself and you wish to send
an error message to SAP, include the following documents:
1. A printout of the problem description (short dump)
To obtain this, select in the current display "System->List->
Save->Local File (unconverted)".
2. A suitable printout of the system log
To obtain this, call the system log through transaction SM21.
Limit the time interval to 10 minutes before and 5 minutes
after the short dump. In the display, then select the function
"System->List->Save->Local File (unconverted)". -
Table maintenance generator : EVENTS : please help me
I need to use table maintenance generator to maintain a custom table through a custom transaction.
I am using event BEFORE SAVE (01). It is working fine but small issues.
1)After entering new entries for some fields(KEY FIELDS), when I press save button, remaining fields values to be populated. Seletion statements have written in FORM of the EVENT 01 (BEFORE SAVE).
But the values for remaining fieldsare not populating immediately and but populating when I press BACK (F3). My requirement is with out presssing BACK or F3 , fields to be populated.
(note: SAP internal code..values are coming into TOTAL structure..then I manipulated this internal table)
PLEASE GUIDE ME, WHICH EVENT TO BE USED. importantly, which internal table/structure (like TOTAL we used for this requirement ) to be used for the proposed new EVENT? (Because lot of R&D to be done to find SAP structure)
2) second requirement is: even after entering new entries, if we press ENTER, then also it should behave like SAVE like in the previous requirement. Please help me to find the EVENT and Internal SAP generated structure (like TOTAL we used for this requirement ).Hi Glen Anthony,
Thanks for replay,
I used foreign key relationship between those 2 internal tables....
I used event 05: When creating a new entry. I want to know the custom logic by which my 2nd Internal table gets automatically updated when i update my 1st Internal table
Thanks Glen. -
Table maintenence generator events
Hi experts,
I am having a table in which I have implemented the table maintenence generator.The requirement is as follows:
Field A:User enters value 'aaa' using F4 help
Field B:Automatically gets populated with the short description corresponding to 'aaa'.
Here the short description depends on the selected value for field A.Hi debansu,
No need to do your coding in events in your case. first of all you understand the internal table used in table Maintainace, The internal tables used are TOTAL and EXTRACT. These table are of string type so you will have to catch your value using offset. To write the logic to popualte the value is very simple in your case. You add one Module in PAI logic of screen of Table maintainance generator in that Module you poupalte the field. for example say for the F4 value of field MATNR you want to populate field MAKTX. then in the one custom PAI moudule you write like this.
SELECT SINGLE FROM MAKT
INTO LF_MAKTX
WHERE MATNR = EXTARCT+3(18)(If Material is the 2nd field after MANDT).
In PAI LOOP is done on EXTARCT internal Table which holds Records in run time.
This will solve your requirment If you are not having F4 help then you can create it by adding one event PROCESS ON VALUE-REQUEST writeen in Flow logic of screen.
We use event where we want to do some validation based on some reasons like Before saving the data in database or before displaying to do the validation of records from table TOTAL. there are diffrent events in Table maintaince but in your case it's not required..
Let me know if you have any more issue.
<b>Kindly reward points for helpfull answers..</b>
Regards
Tanweer Zaki
Message was edited by:
Tanweer Zaki -
Differences between Robot class generated events and real input events
Hello everyone!
I'm having a problem with the translation of the description of the awt.Robot class.
- "This class is used to generate native system input events" -
Does this mean there is no difference between real input events and generated events from the Robot class? Difference in reference to that the generated events can't be recognized as generated events by the os or programs.
Thanks in advance.
Chris B.The Robot class will use an interface provided by the operating system to inject events. Those are very close to 'real' input events, but not quite there. There are, for instance, several games out there which have a protection mechanism against Robot's events to prevent scripting/botting. However, any application that is not paying special attention to the event's source will assume that the input events generated by Robot are actually coming from the user, so you can 'control' any application with the exception of the beforementioned games.
-
How to hide/invisible a column in table maintanence generator????
Hi,
I have a table maintanence genarator of 5 fileds in which there are 2 primary fields. My requirement is to <b>HIDE/INVISIBLE</b> the first column (which is one of the primary key- SPRAS).
How can i do this without coding???
Thanks in advance.ya , i was in change mode...still it is inactive...
Even i tried the same by code but it seems inactive but not getting invisible in the screen.....
MODULE coulmn_modify OUTPUT.
LOOP AT SCREEN.
CASE screen-name.
WHEN '*ZCCBTACT-SPRAS'.
screen-input = 0.
screen-output = 0.
screen-active = 0.
screen-invisible = 1.
MODIFY SCREEN.
WHEN 'ZCCBTACT-SPRAS'.
screen-input = 0.
screen-output = 0.
screen-active = 0.
screen-invisible = 1.
MODIFY SCREEN.
ENDCASE.
ENDLOOP.
ENDMODULE. " coulmn_modify OUTPUT -
Need to validate a existing field in the table maitainence Generator events
Hi EXPERTS,
There is one Z-table and for that TMG also there. There is custom transaction for sm30. Now I need to validate one field BNAME for new entries I have created event -05(creating new entry) it is validating correctly. But now another requirement is if user also wants to change the existing values for the field BNAME it should also be validated needs to populate error mesg and does not allow to save it. I used event 01(before saving data) 07 ( before correcting the contents of selected field) 18 ( after checking whether data has changed)but not working any of these events. Please suggest me which event is suitable for my requirement. Orelse I need to put the code in the flow logic of the screen under PAI module I think this is not a good practice.
Code:
FORM data_changed.
DATA : l_bname TYPE xubname.
CONSTANTS: c_mesg TYPE char16 VALUE 'Invalid SAP User',
c_error TYPE char1 VALUE 'E'.
* Validation on BNAME field
IF zps_capex_appr-bname IS NOT INITIAL.
SELECT SINGLE bname FROM usr01 INTO l_bname
WHERE bname = zps_capex_appr-bname.
IF sy-subrc NE 0.
MESSAGE c_mesg TYPE c_error.
ENDIF.
ENDIF.
ENDFORM. "DATA_CHANGED
Please suggest me how to proceed.
<Added code tags>
<< Priority normalized >>
Awaiting for your replyu2026
Thanks in Advance..
Edited by: Rob Burbank on Mar 2, 2012 9:23 AMHello Sreekanth,
How are you populateing the field zps_capex_appr-bname ? I'm pretty much sure that this is not getting populated at runtime.(put a break-point & check)
In order to access the data in the TMG [Event01|http://help.sap.com/saphelp_nw04s/helpdata/en/91/ca9f0ba9d111d1a5690000e82deaaa/content.htm], we have to use the TMG system tables - TOTAL & EXTRACT.
If your validation of BNAME fails, remember to:
1. Set SY-SUBRC to a non-zero value,
2. Set the flag VIM_ABORT_SAVING to 'X'.
BR,
Suhas -
Table maintenance generator event
Hi experts,
I have a req. in which I need to create events in the TMG.
I implemented the event in case the user entres some specific values, and the fields user name, time and date are automatically populated.
Now there is another requirement in which once the user changes any already existing enty, then the changed by user name, change date and change time should be updated automatically.
How can I achieve this functionality?
Thanks,
Mohit.The following event can fulfil your requirement :
- [Event 01: Before Saving the Data in the Database|http://help.sap.com/saphelp_470/helpdata/en/91/ca9f0ba9d111d1a5690000e82deaaa/frameset.htm]
- [Event 21: Fill Hidden Fields|http://help.sap.com/saphelp_470/helpdata/en/91/ca9f4aa9d111d1a5690000e82deaaa/frameset.htm]
FORM event01.
DATA: f_index LIKE sy-tabix.
FIELD-SYMBOLS <fs> TYPE ANY.
LOOP AT total.
READ TABLE extract WITH KEY <vim_xtotal_key>.
IF sy-subrc EQ 0.
f_index = sy-tabix.
ELSE.
CLEAR f_index.
ENDIF.
CASE <action>.
WHEN neuer_eintrag.
ASSIGN COMPONENT 'CREATEDBY' OF STRUCTURE total TO <fs>.
WHEN aendern.
ASSIGN COMPONENT 'CHANGEDBY' OF STRUCTURE total TO <fs>.
WHEN OTHERS.
CONTINUE.
ENDCASE.
CHECK <fs> IS ASSIGNED.
<fs> = sy-uname.
MODIFY total.
CHECK f_index GT 0.
extract = total.
MODIFY extract INDEX f_index.
ENDLOOP.
sy-subrc = 0.
ENDFORM.
Regards,
Raymond -
Populating Quantity fields in Table Maintainance generator Events.
Hi all,
I have a custom table, in that i have to check the material number and the quantity of the previously present entries and current entry which i am adding in the before save event.
However in the total table.... The value of material is getting populated correctly but the value of the quantity is not the actual one which i have entered, It is taking the value 0.00 at runtime.
Please suggest me the approach when we have to deal with the Quantity fields in the table events.
Thanks in advance for your help.
Regards,
AnujaHi,
The reference for the Quantity field is provided in the Custom table. However the value of the Quantity is taken as 0.00 at run time.
Please refer to the below code.
LOOP AT total.
IF <action> EQ space.
l_wa_temp-matnr = total+3(18).
l_wa_temp-bmenge = total+95(13).
APPEND l_wa_temp TO l_i_temp.
CLEAR l_wa_temp .
ENDIF.
ENDLOOP.
however the l_wa_temp-bmenge is getting populated as 0.00 however the actual value entered for it is 10
Regards,
Anuja -
Table maintainance generator: Event 01
Hi colleagues,
I created a maintenance dialog for a user table a while ago. For administrative purposes I used event 01 'Before Saving the Data in the Database' to add some data automatically to new and changed records.
This worke fine until last week or so.
The documentation (http://help.sap.com/saphelp_erp2005/helpdata/en/a1/e45217a2f511d1a5630000e82deaaa/frameset.htm) tells me I have to use internal table TOTAL.
Now I get a dump in my user routine telling me that TOTAL is a field symbol not assigned. Maybe it is because basis applied some patches but I don't see any source changes.
Help me!
TiA
ClemensClemens,
May be your are right, with the new support packs if the standard code is using a similar variable name that might be the issue.
However, can you go into your code and do a syntax check and reactivate the same?
Regards,
Ravi
Maybe you are looking for
-
Hi All, I am downloading the ALV output to Excel file.I am making use of LIST--->EXPORT--->SPREADSHEET option. My list is having Header, Footer, sub totals and totals.When i transfer the list i am facing following problems 1.Even i am getting the em
-
How do i open a new duplicate window? Two windows with the same content.
Hello, I am switching from IE8 to Firefox. We need to be able to open a new window with the same page displayed instead of going to my homepage. In IE it's called "Open A New Duplicate Window". This feature is very important to us using two screens f
-
NullPointerException on String methods
All, I am trying to get date values on the fly and add them to my sql statement. I have a DateWorker class that provides month, day of month and year. When I use the class in another class, I get NullPointerException. These are just plain ol' String
-
What adapter(s) do I need to connect two DVI-D non-Apple monitors to new 13" MacBook Pro w/Retina?
-
Video DownloadHelper is this a safe download? a warning pop-up warns of damage to the computer
Video DownloadHelper is this a safe download? a warning pop-up warns of damage to the computer.