You are on page 1of 8

Transaction Types

Introduction
Transactions are used to execute each SAP program. The transaction code can be entered directly by the users into the command box in the toolbar , or they can be attached to the SAP Menu.

Purpose
This article allows gives you a basic overview of the different types of transactions that can be created .To create a transaction we use the Tcode SE93. When we goto Tcode SE93 and try to create a Tcode, you will find that 5 types of transactions are available from which you can select th eone appropraite for your particular program. The 5 types of transactions are :

Dialog Transactions Report Transactions Object Oriented Transation Parameter Transation Variant Transaction

Dialog Transaction
Introduction
Dialog Transactions are used to execute programs with type Dialog Module or Module Pool. Programs created with this type cannot be executed without creating a Tcode for it.

Steps
1. 2. 3. 4. 5. 6. To create a Dialog Transation:Take SE93 and click Create. Give the Tcode name to be created and a description adn click Enter. In the dialog box that pops up, select Dialog transaction. Now in the screen that appears, enter the Program name and fill the main screen no . ( The screen whose PBO is to be executed first ). Now select the check box to Inherit GUI Attributes. Save and Check. Execute the Tcode .

Report Transation
Introduction
Report Transactions are used to create TCodes for programs of type 1 or Executable programs.

Eg. Purpose

Let us say, we have created a Type 1 program for displaying the details of selected materials. Suppose our program name is ZMMRDSP001. We will now see the steps required to create a T code for the program. We will set the T Code as ZMMR001. The following are the steps needed to create it.

Steps
1. 2. 3. 4. 5. 6. 7. To create a report transaction:Take SE93 and click Create. Give the T code name as ZMMR001 and a description as Material Display, and click Enter. In the dialog box that pops up, select Report transaction. Now in the screen that appears, enter the Program name ZMMRDSP001. If you want any specific variant to be executed by default, give the variant name. Now select the check box to Inherit GUI Attributes. Save and Check. Execute the T code .

Object Oriented Transaction


Introduction
Object Oriented Transactions can be used when you want to execute a class method directly.

Steps
1. 2. 3. 4. 5. 6. To create a Object Oriented Transaction:Take SE93 and click Create. Give the T code name to be created and a description adn click Enter. In the dialog box that pops up, select Object oriented transaction. Now in the screen that appears, enter the Class Name and give the name of the method that is to be executed first. Now select the check box to Inherit GUI Attributes. Save and Check. Execute the T code .

Parameter Transaction
Introduction
Parameter Transactions are useful when you need to personalize Standard Transactions with some pre-defined values. It involves executing transactions with pre-defined values. It also provides the option of skipping the first screen ( or executing the first screen with your pre-defined values).

Eg. Purpose
We are going to create a transaction code ZMN which allows the user to maintain entries in the table ZMINE which has a table maintenance view. So when the user enters the transaction ZMN, he can directly see the table entries screen.

Steps
1. Goto T code SHD0.

2.

Enter the Transaction Code ZMN and give a valid

3. 4. 5. 6.

description. Choose Parameter Transaction Radio Button and Continue. Enter details in the subsequent screen as shown to the right and click Enter. Now in the bottom part you can see a section Default Values. In here, using F4 help , you can see teh fields(screen field n ames) available on that particular screen( SM30 in this case). Select screen field VIEWNAME and UPDATE now. In the right side ( Value ) add ZMINE ( your view name which has a table maintenance view) against VIEWNAME and X against UPDATE. [FYI: Update is a button present in the SM30 screen which is clicked to maintain data. Setting that value to X will give the effect of clicking the Maintain button on SM30 with viewname as ZMINE.

7.

Now Save and Check.And Execute. If there are no errors, you should be able to see your maintenance screen directly.

Output
When the user now clicks the transaction ZMN the screen he sees will be

Variant Transaction
Introduction
Transaction Variants can be very useful in making design level changes in Standard Transactions. They can also be sued to set default values on screens and to set screen field properties.They can then be assigned to Standard T code itself, So that these changes get reflected for all users accessing the T code , or we can set separate T code for the same.

Eg. Purpose
In this document , we will create a Transaction Variant for the T Code VA01, in which we will make a variant transaction(ZVA01) of VA01 in which the initial screen ( with order type etc) need not be filled as they will be defaulted and PO number made mandatory .

Steps
1. 2. Goto T Code SHD0. Enter the Transaction Code for which you want to create a variant. In this case, enter Tcode VA01 and give a name for your transaction variant. Say

ZVA01.

3. 4.

Now click the Create button. You will be taken to the Tcode VA01. Enter values in the initial screen as you would during normal processing and click

enter.

5.

Now a new screen will pop up showing all the fieldnames and properties that can be changed.

6. 7.

Give the values in the pop up as given above and click ENTER to go to the next screen. Similarly, you can set any properties you need in the screen and on clicking enter , the properties tab will pop up. You can makethe desired changes there. I will set PO number to required and the Document Currency to INR. I will also hide the tabstrip for Shipping details. So the values in the pop ups will be

8. Note that several pop ups will show.This is because a popup for each sub screen will be displayed. 9. Now click Exit and Save button. 10. All the values entered and shown will get displayed in a single screen. You can make any changes necessary and then save with a description. 11. Save all and assign each to package. 12. Now click back and you will be taken to the initial screen in SHD0. Save. 13. Now take T Code se93 and give a new Tcode for executing the variant and click Create. 14. In the radio button options that appear, select variant Transaction. 15. Now go inside, and give T Code as VA01 and variant s ZVA01 and select cross Client Check Box. 16. Now select the check box to Inherit GUI Attributes. Save and Check. 17. Now execute your transaction.

Output
You are now directed directly to the 2nd screen after skipping the initial screen with the values you have set by default through your variant. Further , if you try saving without the PO number, it will give a message asking you to fill the PO

number.

Conclusion So this is how the different types of transactions are created . Make sure you assign the correct type to the transaction or your program may not work correctly. Happy Coding :D.

You might also like