‎2006 Dec 08 10:22 AM
could someone explain me the concept of using pernr structure/table in the program i.e
table :pernr and
get pernr.
Also, explain what exactly the above mentioned statements do (in detail)
answers will be rewarded
‎2006 Dec 08 10:25 AM
Hi rohan,
1. table :pernr
PNP returns the data in a pre-define format/structure.
That pre-defined format is the structure PERNR.
If we do not declare it,
then the PNP does not return anything.
2. get pernr
To get the various records, as per the selection screen criteria,
we use get PERNR.
The data is put in the structure PERNR,
so that we can use it further.
If there are 100 records, then GET will be automatically fired 100 times.
regards,
amit m.
‎2006 Dec 08 10:29 AM
you declare some tables like tables: pernr,p0001.
corresponding declarations like infotypes 0001,0002. except pernr.
get pernr event bring all the data as per selection screen for all the info type you declare into corresponding p0001,p0002...etc.(only for the tables in which we declare infotype ) these are structures in se11 and internal tables at runtime in our program.
then we can process the required data.
tables:pernr,p0001,p0002
infotypes:00001,0002.
‎2006 Dec 08 10:31 AM
‎2006 Dec 08 10:47 AM
Hi,
If you look into the logical database thro' tcode Se36,you can find PERNR is the node.
So we need to define tables pernr if we are using PNP logical database.
Get pernr will be triggered after start-of-selection.
Based on selection criteria specified,it fetches each employee records in ascending order.
Once an employee record is fetched,we can use macro rp_provide_from_last to process the current employee record.
If you use
provide * from p0001 between pn-begda and pn-endda.
write : / p0001-pernr p001-stell.
endprovide.
after get pernr,it will give you all the records of an employee.
You can use pernr-pernr after get pernr to find out the employee no. fetched.Basically pernr is a structure in database without any database table.
Kindly reward points if it helps.