Sapnote Medidas Dinamicas PDF
Sapnote Medidas Dinamicas PDF
Sapnote Medidas Dinamicas PDF
Summary
Symptom
Dynamic actions are not processed (as expected).
Dynamic actions are processed - although not expected.
More Terms
T588Z
Solution
The following information should help you to prevent undesired system
behavior and errors or to find errors more easily.
Incorrect spelling
o As relational operators, only the characters >, <, = <>, >=, <= are
supported (EQ, NE and so on are not known).
Known fields
The fields of the infotype that triggers the dynamic action are known.
Also, the table contents of the tables T001P (Personnel Area/Subarea) and
18.07.2007 Page 1 of 6
Note 386027 - Dynamic actions
T503 (Employee Group/Subgroup) and the structures PSPAR and PSAVE are known
. The structures PSPAR and PSAVE are also known. T001P, T503 and PSPAR
contain the values that are valid at the start date of the current record.
PSAVE contains the old values of the infotype record.
If the start date is changed, PSAVE is initial because, from the technical
point of view, this is not a change but a deletion and recreation.
Therefore, old values of the infotype record cannot be defined.
As of Release 4.5, you can use the fields of structure RP50D, for example,
by calculating or filling them in a FORM routine and then using them for
checking or for the value specification when you maintain an infotype
record.
We can only guarantee the information contained in this note for infotypes
0nnn.
For the dynamic actions only the actions INS, COP, MOD and DEL are
supported. This differs from personnel actions. INSS is not carried out. In
general, you can use the action LIS9. However, under certain circumstances,
problems may occur. Therefore, you should try to display LIS9 with MOD or
DEL.
Using a distribution list, you can have a mail sent to any Internet
address. The following specifications are required: In characteristic M0001
(or in a corresponding copy), characteristic RCIEV (or a corresponding
copy) is specified in the return value for NAME1. In characteristic RCIEV,
the eight-place name of a distribution list needs to be entered as return
value in the form V-xxxxxxxx. This distribution list must be defined in the
Business Workplace (transaction SBWP) and can also contain recipients of
the type 'Internet address'.
In SAPconnect (transaction SCOT), suitable nodes must be defined for the
relevant address types. If the system setting does not include the
automatic sending of the mails, you can trigger the transmission requests
using SAPconnect. In SAPconnect (transaction SOST), transmission requests
can also be analyzed.
18.07.2007 Page 2 of 6
Note 386027 - Dynamic actions
To avoid errors when programming and running the session, only the static
actions are processed in batch input. Calls of infotypes that are triggered
by dynamic actions should be realized by separate transaction calls.
Example:
nnnn ... 02 P ...
nnnn ... 02 I ...
nnnn ... 06 I ...
If you change the infotype nnnn and if the condition mentioned in the P
statement is fulfilled, both I statements are executed. If infotype nnnn is
inserted, the system always - without check - executes the second I
statement. If you want that the second I statement is always executed in
the change case, too, you require a P statement with a (Dummy-) condition
that is always filled (for example, SY-DATUM=SY-DATUM) before the second I
statement.
Dynamic actions are not executed, in other words, they are deactivated, if
the action indicator is not equal to P, I, W, V, F, M.
ALL plausibility checks which are linked with OR must have the extension
/X.
Example 1:
Condition 1/X
Condition 2/X
Condition 3
Meaning: (Condition 1 OR condition 2 ) AND condition 3
Example 2:
18.07.2007 Page 3 of 6
Note 386027 - Dynamic actions
Condition 1/X
Condition 2
Condition 3
Meaning: Condition 1 AND condition 2 AND condition 3,
in other words, the extension /X for condition 1 has no effect.
However, the author of this condition probably wanted to
define the condition of example 1.
Error messages that occur when dynamic actions are processed cause the
screen of the relevant infotype to be sent - even if the dynamic action
should be processed in the background. Example: Specification of a subtype
that does not exist (for example, due to incorrect spelling of the
subtype).
Make sure that you only use W statements after I statements since,
otherwise the reference is hardly comprehensible and statements may be
executed at a time which is not intended.
Dynamic actions are executed after you save the infotype which triggers
them.
If you want to use a dynamic action to process additional changes for the
same infotype in the background, for example, if you want to set a lock
indicator, note that a dynamic action may not be the appropriate method.
The reason is that it is only processed after the maintenance action is
saved. Also, it may terminate due to unexpected messages which can cause
the relevant infotype to be sent. You should use a user exit instead.
Example:
0028 ... P ...
0028 ... I INS,0019
0028 ...
0028 ... P ...
0028 ... F XYZFORM(ZCUSTPROG)
0028 ... I INS,0041
0028 ... W P0041-field=RP50D-DATE1
You should only use a FORM routine in a dynamic action to get or check data
for a following action within the dynamic action. The following should
explain this:
You want to change the entry date (transaction PA41). You select four
infotypes for changes but only change the entry date for two infotypes -
and 'suddenly' you are on the initial screen of HR master data maintenance
(transaction PA30). What is the cause? A dynamic action was defined for the
second changed infotype when a FORM routine was called. It contained the
statement LEAVE TO TRANSACTION 'PA30'.
18.07.2007 Page 4 of 6
Note 386027 - Dynamic actions
Example:
I COP,XXXX,,,(PYYYY-BEGDA),(PYYYY-ENDDA)
W PXXXX-BEGDA=(PYYYY-BEGDA)
W PXXXX-ENDDA=(PYYYY-ENDDA)
If you want to set a default for the entry and the leaving date for the
copied infotype record, you require the W statement. The I statement is for
selecting the infotype record to be copied.
For time constraint 3 more than one infotype record may be selected because
of an I action. However, a following W action is only executed once.
For the 'Monitoring of Dates' infotype, you can add or subtract a number of
time units to/from an initial date. The system supports the time units Days
(010), Weeks (011), Months (012) and Years (013). The time units are
specified in table T538T (Units of Time/Measurement Texts). The number is
assigned to field P0019-VTRAN, the time unit to field P0019-VTRZH, and the
operation (+ or -) to field P0019-VTROP. Before, you must assign an initial
date for the calculation to field P0019-TERMN.
Example:
I INS,0019,30
W P0019-TERMN=P0028-BEGDA
W P0019-VTRAN='1'
W P0019-VTRZH='013'
W P0019-VTROP='+'
For the start date (P0028-BEGDA) of the infotype Internal Medical Service
(0028), the number (P0019-VTRAN) of a certain time unit (P0019-VTRZH) is
added in accordance with the table Units of Time/Measurement Texts using
operation '+' (P0019-VTROP). In this case, this means plus one year.
Header Data
Release Status: Released for Customer
Released on: 17.04.2007 08:54:37
Priority: Recommendations/additional info
Category: Consulting
18.07.2007 Page 5 of 6
Note 386027 - Dynamic actions
Related Notes
Number Short Text
547603 No mail sent for hiring action
Attributes
Attribute Value
Transaction codes HIER
Transaction codes PA30
Transaction codes PA41
18.07.2007 Page 6 of 6