Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Parameter and Variant Transaction

Former Member
4,376

Hi

Please explain what is Parameter and Variant Transaction. Please give an example for this.

Best regards

Partha

Hi

Please explain what is Parameter and Variant Transaction. Please give an example for this.

Best regards

Partha

4 REPLIES 4
Read only

Former Member
Read only

naimesh_patel
Active Contributor
0 Likes
1,871

Hello,

Parameter Transaction:

If you want to call any transaction and you want to pass the values for the screen fields of the transation. Like you had created one table maintainace and you want to create the transaction for that, then you have to use the this type of transaction.

Variant Transaction.

IF you want to start any particular transaction with the variant then you have to create this type of transaction.

Regards,

Naimesh

Read only

Former Member
0 Likes
1,871

Hi,

<b>Variant Transaction</b>

How to use Transaction Variants to make your fields Mandatory, Hidden or Display?

You can hide unwanted screens and fields in any of the standard SAP programs without changing any of the standard programs. Additional features such, as making the variant, as default on the standard SAP transaction code is only available on 4.6x.

Steps :-

Transaction SHD0 - Create a variant for the required transaction by changing the layout through hiding fields and screens.

Transaction SE93 - Create a variant transaction (e.g. for VA02 you can name it as ZA02). Next allocate the transaction variant to this variant transaction.

Create and change the Zxxx area menu with the new transaction variant. In this way, the user does have to remember any extra transaction codes.

In 4.6c, you can default your transaction variant as the standard variant. (SHD0 - Edit -> Activate/Deactivate as standard variant)

An example for using transaction variant (restricting the field display for CO11N - Goods movement) :-

If you want to restrict changes to the fields in Goods movement for one group of users.

1. Create a transaction variant for CO11N

2. Create a new transaction code for the transaction variant and assign an authorization object to it

3. Divide the users into this two-transaction code. Those who can change the field using CO11N. For those that have limited field change, give them the authorization for ZCO11 (this is a new transaction code you have to create).

<b>Parameter transaction</b>

Create Parameter transaction for SM30

Assuming that you want the user to maintain a table or view using SM30 but you do not want them to see the initial screen of SM30. For e.g. V023 - Material Group.

Steps tested in 4.6x :-

SE93 - Type in a transaction name e.g. ZV023

Click create - choose parameter transaction

In the Create Parameter transaction screen, fill in the following fields :-

Transaction SM30

Tick Skip initial screen

Tick Inherit GUI attributes

Name of screen field Value

VIEWNAME V023

UPDATE X

Press F8 or click the Test button for testing.

Save it and with the required authorization, the user will be able to use transaction code ZV023 to maintain the material group.

Check these thread also

Transaction Variant

Parameter transaction

Rgds,

Prakash

Read only

Former Member
0 Likes
1,871

HI,

<b>PARAMETERS:</b> You use the PARAMETERS statement to declare variables, similarly to the DATA statement Variables declared with the PARAMETERS statement are called parameters. For each parameter declared, an input field appears on the corresponding selection screen. On the left hand side of the input field, the name of the parameter is displayed as text. You can modify this text as selection text. Values entered into the input field by the user are assigned to the corresponding variable while the system processes the selection screen. The position of the statement in the declaration part of the program determines the selection screen to which the input field belongs.

The basic form of the PARAMETERS statement is as follows:

PARAMETERS <p>[(<length>)] [TYPE <type>|LIKE <obj>] [DECIMALS <d>].

<b>VARIANT TRANSACTION:</b> How to use Transaction Variants to make your fields Mandatory, Hidden or Display?

You can hide unwanted screens and fields in any of the standard SAP programs without changing any of the standard programs. Additional features such, as making the variant, as default on the standard SAP transaction code is only available on 4.6x.

Steps :-

Transaction SHD0 - Create a variant for the required transaction by changing the layout through hiding fields and screens.

Transaction SE93 - Create a variant transaction (e.g. for VA02 you can name it as ZA02). Next allocate the transaction variant to this variant transaction.

Create and change the Zxxx area menu with the new transaction variant. In this way, the user does have to remember any extra transaction codes.

In 4.6c, you can default your transaction variant as the standard variant. (SHD0 - Edit -> Activate/Deactivate as standard variant)

An example for using transaction variant (restricting the field display for CO11N - Goods movement) :-

If you want to restrict changes to the fields in Goods movement for one group of users.

1. Create a transaction variant for CO11N

2. Create a new transaction code for the transaction variant and assign an authorization object to it

3. Divide the users into this two-transaction code. Those who can change the field using CO11N. For those that have limited field change, give them the authorization for ZCO11 (this is a new transaction code you have to create).