Application Development 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: 

Regarding BAPI " HR_MAINTAIN_MASTERDATA"

Former Member
0 Kudos

Can I use a structure to insert values into a standard table hrp5125 using the BAPI " HR_MAINTAIN_MASTERDATA" .

Do I need to change the definition of BAPI, to insert the structure values again into the table (inside the " HR_MAINTAIN_MASTERDATA")

1 ACCEPTED SOLUTION

suresh_datti
Active Contributor
0 Kudos

First off, HR_MAINTAIN_MASTERDATA is not a BAPI & secondly it can be used to mainatin the PA infotypes only. So you will not be able to insert values into HRP5125 table using this function call.

~Suresh

10 REPLIES 10

0 Kudos

I am not sure how the more exhaustive BAPI "BAPI_HRMASTER_SAVE_REPL_MULT" can be of use to you. Be sure to go through the documentation before you use it!

Hope this helps,

Sudhi

suresh_datti
Active Contributor
0 Kudos

First off, HR_MAINTAIN_MASTERDATA is not a BAPI & secondly it can be used to mainatin the PA infotypes only. So you will not be able to insert values into HRP5125 table using this function call.

~Suresh

0 Kudos

Hi Suresh,

I am needfully looking to insert values into hrp5125 and hrp5126 using a FM or a BAPI (read that I can't use simple insert). Can you please tell me how I should be doing this.

This whole operation am doing inside a customized HR FM "ZHRWPC_EREC_CREATE_EREC_OBJECT"

amit_khare
Active Contributor
0 Kudos

What exactly you are trying to say here, Its not clear.

As for using this FM check this report HKRULQC0.

you have to pass field names along with values inthe table import PROPOSED_VALUES.

e.g.

move '0416' to proposed_values-infty.

move '00' to proposed_values-seqnr.

move 'P0416-PERNR' to proposed_values-fname.

move gen_p0416-pernr to proposed_values-fval.

append proposed_values.

move '0416' to proposed_values-infty.

move '00' to proposed_values-seqnr.

move 'P0416-SUBTY' to proposed_values-fname.

move gen_p0416-qctyp to proposed_values-fval.

append proposed_values.

Regards,

Amit

If it is for PA infotypes only then just ignore this information.

Message was edited by:

Amit Khare

0 Kudos

Thanks all,

So what I should be using to insert into standard tables hrpXXXX.

I been reading that simple inserts should be avoided. Or can I go ahead and finish it off with insert.

Thanks

bryan_cain
Contributor
0 Kudos

I've never used that infotype before, but you can try RH_INSERT_INFTY.

0 Kudos

Hi there!,

What is RH_INSERT_INFTY. I am trying to insert values into standard HR tables hrpxxxx.

Thanks

0 Kudos

I guess your reqt is erecruiting related.. anyay the function module RH_INSERT_INFTY can be used to insert records into HRPnnnn tables. Pl take a look at the Std report RHVAKRIO that inserts records

into HRP1007.

~Suresh

0 Kudos

Sorry - as mentioned by Suresh it's a function module that will allow you to insert data into the standard HRP* tables. Do a where-used on the FM to see some good examples (I couldn't find the example suresh mentioned, but I may have mis-typed). Basically, you pass a table of the structure P<INFTY> to the FM and it creates the record for you. However, I do not see a structure P5125 in my 4.6c system, so you may not be able to use this FM after all... You'll need to do some more research.

0 Kudos

To reply to myself here - don't fret over the fact that I can't find that structure in my 4.6c system - I can't find that infotype table either! When I did HR programming, it was at another client, so who knows what you may find in your system...