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 Id

Former Member
0 Likes
1,330

Hi,

Can anybody explain me in detail what is Parameter Id,How to create it and its use.

Regards,

Deepak.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
995

Hi,

To fill the input fields of a called transaction with data from the calling program, you can use the SPA/GPA technique. SPA/GPA parameters are values that the system stores in the global, user-specific SAP memory. SAP memory allows you to pass values between programs. A user can access the values stored in the SAP memory during one terminal session for all parallel sessions. Each SPA/GPA parameter is identified by a 20-character code. You can maintain them in the Repository Browser in the ABAP Workbench. The values in SPA/GPA parameters are user-specific.

ABAP programs can access the parameters using the SET PARAMETER and GET PARAMETER statements.

To fill one, use:

SET PARAMETER ID <pid> FIELD <f>.

This statement saves the contents of field <f> under the ID <pid> in the SAP memory. The code <pid> can be up to 20 characters long. If there was already a value stored under <pid>, this statement overwrites it. If the ID <pid> does not exist, double-click <pid> in the ABAP Editor to create a new parameter object.

To read an SPA/GPA parameter, use:

GET PARAMETER ID <pid> FIELD <f>.

This statement fills the value stored under the ID <pid> into the variable <f>. If the system does not find a value for <pid> in the SAP memory, it sets SY-SUBRC to 4, otherwise to 0.

For further refer this link.

[http://help.sap.com/saphelp_erp2004/helpdata/en/9f/db9e0435c111d1829f0000e829fbfe/content.htm]

[;

Reward if helpful.

Best regards

Sourabh

8 REPLIES 8
Read only

Former Member
0 Likes
995

Hi,

SAP memory is a memory area to which all main sessions within a SAPgui have access. You can use SAP memory either to pass data from one program to another within a session, or to pass data from one session to another. Application programs that use SAP memory must do so using SPA/GPA parameters (also known as SET/GET parameters). These parameters can be set either for a particular user or for a particular program using the SET PARAMETER statement. Other ABAP programs can then retrieve the set parameters using the GET PARAMETER statement. The most frequent use of SPA/GPA parameters is to fill input fields on screens

example:

program1:


set parameter id 'TEST' field 'value'.

program2:


data:val(10).
set parameter id 'TEST' field val.
write:/ val.

rgds,

bharat.

Read only

Former Member
0 Likes
995
Read only

Former Member
Read only

Former Member
0 Likes
995

Hi,

SE80 -> click on EDit Objects -> select Tab - More -> youwill find SET/GET Parameter ID

You can create it from here . It is good practice to use SE80

Hope its Useful,

Regards,

SUNIL

Edited by: Sunil Saini on Apr 15, 2008 1:33 PM

Read only

Former Member
0 Likes
995

Hi,

start SE80, click on icon Edit Object, a popup will appear, enter the name of the parameter ID (Z...) and click on Create on the bottom of the popup...

Generally Parameter ID for any Z field is set at Data Element level in Further Characteristics tab. give a name at data element level and double click on that name , system window open to create the mentioned parameter id.

or

write a statement like

set paramet id 'ZTES' field ztest-test.

double click on ZTES, system popup will come , give name to it and save it.

you could also use function..

'RS_PARAMETER_ADD'

Read only

Former Member
0 Likes
996

Hi,

To fill the input fields of a called transaction with data from the calling program, you can use the SPA/GPA technique. SPA/GPA parameters are values that the system stores in the global, user-specific SAP memory. SAP memory allows you to pass values between programs. A user can access the values stored in the SAP memory during one terminal session for all parallel sessions. Each SPA/GPA parameter is identified by a 20-character code. You can maintain them in the Repository Browser in the ABAP Workbench. The values in SPA/GPA parameters are user-specific.

ABAP programs can access the parameters using the SET PARAMETER and GET PARAMETER statements.

To fill one, use:

SET PARAMETER ID <pid> FIELD <f>.

This statement saves the contents of field <f> under the ID <pid> in the SAP memory. The code <pid> can be up to 20 characters long. If there was already a value stored under <pid>, this statement overwrites it. If the ID <pid> does not exist, double-click <pid> in the ABAP Editor to create a new parameter object.

To read an SPA/GPA parameter, use:

GET PARAMETER ID <pid> FIELD <f>.

This statement fills the value stored under the ID <pid> into the variable <f>. If the system does not find a value for <pid> in the SAP memory, it sets SY-SUBRC to 4, otherwise to 0.

For further refer this link.

[http://help.sap.com/saphelp_erp2004/helpdata/en/9f/db9e0435c111d1829f0000e829fbfe/content.htm]

[;

Reward if helpful.

Best regards

Sourabh

Read only

Former Member
0 Likes
995

hi,

The SET PARAMETER ID will set the value of the parameter that we specify in the SAP Memory.

This value is accesible across transactions.

For example, if you create a sales order in VA01 transaction, you can see the new sales order number already present, if you open the VA03 transaction.

This is because the VA01 transaction uses the SET Parameter statement in its main program.

check the belwo link

http://help.sap.com/saphelp_nw04/helpdata/en/9f/db9e0435c111d1829f0000e829fbfe/content.htm

if helpful rewarde with points

Regards,

pankaj

Read only

Former Member
0 Likes
995

Hi,

By using paramter id we can fill proposed values from SAP memory.

the field values has stored under this paramter id.

To create this, in the SE51 you can pass this in the screen painter attributes of particular field.

Regards,