Using FM RH_INSERT_INFTY
Hi,
I want to use FM RH_INSERT_INFTY in background job. If there is no error this FM works as expected, but if an error comes, this FM terminates the background job without any error.
How can i catch errors from this FM in background job?
Regards,
Ashish Gupta
Hi Richard,
Thanks a lot for your reply.
I am inserting a record in IT1001 (cost centre relationship 1001).
I have used this FM in method FLUSH of HCM Process and Forms Advanced Generic service. If i create a normal program inse38, this FM gives error in exception as sy-subrc = 2, which is correct. But FLUSH method is run in background with user WF-BATCH.
Now what happens is, there is a FM HRCA_COBL_CHECK in this FM RGH_INSERT_INFTY. Now what happens is HRCA_COBL_CHECK give an error message KI 260. To display this error message it is looking for screen which is not available in background and hence just terminates the processing of program without returning any error message or short dump.In HR_INFITYPE_OPERATION we have option to supress dialog but no similar option in this FM.
regards,
Ashish Gupta
Similar Messages
-
Error using FM RH_INSERT_INFTY
Hi Guy's
Im facing an issue while using FM RH_INSERT_INFTY to insert data in Infotype HRP1028
its raising a exception "2-ERROR_DURING_INSERT "
DATA : it_hrp1028 TYPE STANDARD TABLE OF HRP1028 INITIAL SIZE 0.
it_hrp1028-PLVAR = '01'.
it_hrp1028-otype = 'S'.
it_hrp1028-objid = positionid.
it_hrp1028-infty = '1028'.
it_hrp1028-istat = '1'.
it_hrp1028-begda = begda.
it_hrp1028-endda = endda.
it_hrp1028-build = build.
APPEND it_hrp1028.
CALL FUNCTION 'RH_INSERT_INFTY'
EXPORTING
FCODE = 'INSE'
VTASK = 'S'
ORDER_FLG = 'X'
COMMIT_FLG = 'X'
AUTHY = 'X'
PPPAR_IMP =
OLD_TABNR = ' '
REPID = ' '
FORM = ' '
KEEP_LUPD =
WORKF_ACTV = 'X'
TABLES
INNNN = it_hrp1028
ILFCODE =
EXCEPTIONS
NO_AUTHORIZATION = 1
ERROR_DURING_INSERT = 2
REPID_FORM_INITIAL = 3
CORR_EXIT = 4
BEGDA_GREATER_ENDDA = 5
OTHERS = 6
IF SY-SUBRC EQ 0.
CALL FUNCTION 'RH_UPDATE_DATABASE'
EXPORTING
vtask = 'S'
EXCEPTIONS
corr_exit = 1
OTHERS = 2.
ENDIF.
Thanks in advance for the helpHi everybody,
Did you solve this issue? I am facing a similar problem with FM RH_INSERT_INFTY, it's also raising a exception "2-ERROR_DURING_INSERT". In my case, i'm trying to insert a new record for the infotype 1028 but not as a position (S), im trying to insert the record as object type 'O'. So, in this case I don't have the field hrp1028-build.
Is there any other way to do this? -
How to save requisitions without using E-Recruiting
Hello All,
Is there a way, to save requisitions data without using the E-Recruiting Web pages?
Is there a Function module or a Class or a BAdI that I can use?
We want to use a Interface that will send a flat fille with a lot of data
and then to handle it in the same way the SAVE button on E-Recruiting does...
Any Suggestions?
Best Regards,
Eran
SAVE THE DATE 01-01-2011 ****Hi Roman,
The flat file will come from other systems .
It will store Requisitions details and the program/interface will have to proccess these records and create or update the infotypes according to them...
Someone told me that it would be a bad thing to use classes and pointed out that there are FM like RH_* that wiil do the same
I tried to use FM 'RH_INSERT_INFTY' just to see if any record was entered ,but nothing happened...
HRP1000 didn't get the new record
What did I do wrong? What is the right way? FM's or Classes?
Best Regards,
Eran
DATA: X1000 LIKE P1000 OCCURS 1 WITH HEADER LINE.
X1000-MANDT = SY-MANDT.
X1000-PLVAR = '01'.
X1000-OTYPE = 'NB'.
X1000-INFTY = '1000'.
X1000-ISTAT = '1'.
X1000-BEGDA = sy-datum.
X1000-ENDDA = '99991231'.
X1000-LANGU = 'B'.
X1000-SHORT = 'ERAN'.
X1000-STEXT = 'ERAN TEST'.
append x1000.
* 1. Reset standard authorization
CALL FUNCTION 'RH_AUTHORITY_CHECK_OFF'.
* 2. Insert new row into Infotype 1000 for position with new name
CALL FUNCTION 'RH_INSERT_INFTY'
EXPORTING
* FCODE = 'INSE'
VTASK = 'S'
* ORDER_FLG = 'X'
* COMMIT_FLG = 'X'
* AUTHY = 'X'
* PPPAR_IMP =
* OLD_TABNR = ' '
* REPID = ' '
* FORM = ' '
* KEEP_LUPD =
* WORKF_ACTV = 'X'
TABLES
INNNN = X1000
* ILFCODE =
* EXCEPTIONS
* NO_AUTHORIZATION = 1
* ERROR_DURING_INSERT = 2
* REPID_FORM_INITIAL = 3
* CORR_EXIT = 4
* BEGDA_GREATER_ENDDA = 5
* OTHERS = 6
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
COMMIT WORK.
* 3. Set standard authorization
CALL FUNCTION 'RH_AUTHORITY_CHECK_ON' .
SAVE THE DATE 01-01-2011 ****
More convenient to use, More efficient search , Easier to find... -
Get error in FM RH_INSERT_INFTY'
Hi Guy's
Im facing an issue while using FM RH_INSERT_INFTY to insert data in Infotype HRP9503
its raising a exception "2-ERROR_DURING_INSERT "
Regards,
S.VelsankarHi,
Debug the form routine INSERT_INFTY in the FM. In the form routine, there are places where subrc = 16 is set. check the same.
Sujay -
FM RH_INSERT_INFTY lock by CL_HR_ALEOX_BADI in production system
Hi Gurus,
I am using FM RH_INSERT_INFTY in a Z.. Report in order to massive charge the organizational structure. But it's taking so long, and when I see in SM50 is performing in report "CL_HR_ALEOX_BADI==============CP" in production system.
Does anybody knows if something has to be set up before execute the class CL_HR_ALEOX_BADI.
Any help is very useful.
Thanks in advance,
RegardsThis is my entry in SM50.
Regards -
Hi,
I am trying to create entry in infotype 1001 using FM RH_INSERT_INFTY. The problem is that checks built in BADI are not getting executed. Another problem is that there are few custom checks built in PAI of infotype 1001 that are also not executed.
Is there any way that all these checks are executed while using FM RH_INSERT_INFTY or any other FM just like the way they are executed when someone creates via PP01.
Regards,
AmitHi,
Amit Mittal Regarding this you can contact Craig.
just send him a mail he will solve it.
[email protected]
or [email protected]
this is to Mr.Amit(1353 posts,2350points).
regards
vijay -
Custom HRP Infotype for e-Recruiting
I am trying to create a custom HRP infotype to be used in our e-Recruiting system. I want to be able to update the infotype using the SAP standard RH_INSERT_INFTY and like function calls. However my entry in table t777d won't let me change the Update type to anything other than blank (No update via personnel planning update task). I also am having issues which I am not sure if this stems from that problem or not but when I try to use the RH_INSERT_INFTY I get a short dump when it tries to do an insert with a vtask of D because the data doesn't appear to be mapped to the correct fields. My input table type is of type p9xxx and it seems to be mapped correctly until the last stage when it actually tries to insert the line into the table. Any suggestions for what might be wrong? I have checked to make sure that the p9xxx and hrp9xxx have the same structure and they appear to match correctly
You could search/post this question in the HR forum...
-
Runtime error when inserting rows in hrp1018 and hrt1018 tables
Hi All,
I have a requirement to insert row in hrp1018 and hrt1018 tables.These tables are interlinked.So, I have used FM 'RH_INSERT_INFTY'. The exact code which I have used is as follows.
*****************************************code***************************************************************
<< Please post only the relevant portion of the code >>
The runtime error which is coming is as follows:
Error analysis
An internal error in the database interface occurred during access to
the data of table "HRT1018 ".
The situation points to an internal error in the SAP software
or to an incorrect status of the respective work process.
For further analysis the SAP system log should be examined
(transaction SM21).
For a precise analysis of the error, you should supply
documents with as many details as possible.
Please let me know why this error is coming.I am not able to find out mistake in the FM and form used in the code.
Thanks in advance,
BBKrishna.
Edited by: Rob Burbank on Jun 9, 2009 1:31 PMI am adding the code once again.Please let me know why the error is coming up.
lv_mproj = 'BLDNG'.
wa_p1018-mandt = sy-mandt.
wa_p1018-otype = '9M'.
wa_p1018-objid = '50009650'.
wa_p1018-begda = '20090608'.
wa_p1018-endda = '99991231'.
wa_p1018-infty = '1018'.
wa_p1018-plvar = '01'.
wa_p1018-otype = '9M'.
wa_p1018-istat = '1'.
append wa_p1018 to it_p1018.
repid = sy-repid.
*Updating hrp1018 and hrt1018 tables
CALL FUNCTION 'RH_INSERT_INFTY'
EXPORTING
FCODE = 'INSE'
VTASK = 'D'
AUTHY = ' '
REPID = repid
FORM = 'FILL_TABS'
TABLES
INNNN = it_p1018
EXCEPTIONS
NO_AUTHORIZATION = 1
ERROR_DURING_INSERT = 2
REPID_FORM_INITIAL = 3
CORR_EXIT = 4
BEGDA_GREATER_ENDDA = 5
OTHERS = 6
IF SY-SUBRC <> 0.
CALL FUNCTION 'BALW_BAPIRETURN_GET'
EXPORTING
TYPE = SY-MSGTY
CL = sy-msgid
NUMBER = SY-MSGNO
PAR1 = ' '
PAR2 = ' '
PAR3 = ' '
PAR4 = ' '
LOG_NO = ' '
LOG_MSG_NO = ' '
IMPORTING
BAPIRETURN = return_rec
EXCEPTIONS
ONLY_2_CHAR_FOR_MESSAGE_ID = 1
OTHERS = 2
IF SY-SUBRC <> 0.
lv_mproj = text-011
ELSE.
ii_return = return_rec.
CONCATENATE ii_return-type '-' ii_return-message
INTO lv_err_msg SEPARATED BY SPACE.
ENDIF.
ENDIF.
*RHCD_TAB-PROZT
FORM fill_tabs TABLES ins_tab
USING ins_set ins_index.
DATA : BEGIN OF set.
INCLUDE STRUCTURE wplog.
DATA : END OF set.
DATA: BEGIN OF h_pt1018. "to initialize INS_TAB
INCLUDE STRUCTURE pt1018.
DATA: END OF h_pt1018.
REFRESH ins_tab.
set = ins_set.
CASE set-infty.
WHEN '1018'.
h_pt1018-posnr = lv_mproj.
h_pt1018-prozt = '100.00'.
IF NOT ( h_pt1018 IS INITIAL ).
CLEAR ins_tab.
ins_tab+36(8) = lv_mproj. "h_pt1018.
ins_tab+134(5) = '100.00'.
APPEND ins_tab.
ENDIF.
ENDCASE.
ENDFORM. -
I am trying to create a custom HRP infotype to be used in our e-Recruiting system. I want to be able to update the infotype using the SAP standard RH_INSERT_INFTY and like function calls. However my entry in table t777d won't let me change the Update type to anything other than blank (No update via personnel planning update task). I also am having issues which I am not sure if this stems from that problem or not but when I try to use the RH_INSERT_INFTY I get a short dump when it tries to do an insert with a vtask of D because the data doesn't appear to be mapped to the correct fields. My input table type is of type p9xxx and it seems to be mapped correctly until the last stage when it actually tries to insert the line into the table. Any suggestions for what might be wrong? I have checked to make sure that the p9xxx and hrp9xxx have the same structure and they appear to match correctly.
Thanks,
StephanieYou could search/post this question in the HR forum...
-
Bapi to upload data for hrp1001
Hi is there any standard Bapi to upload data in 1001.
I know it can be done by lsmw or BDC ..but i wanted to aout any bapiHi pratyush,
Try using FM RH_INSERT_INFTY.
Before RH_INSERT_INFTY, call function RH_PM_ENQUEUE, after RH_INSERT_INFTY, call function RH_PM_DEQUEUE.
Regards,
Dilek -
RH_UPDATE_DATABASE
Hi Guys,
I am using FM RH_INSERT_INFTY with Vtask = 'B'.
This way I process all the records and they are updated in an internal buffer.
After processing all the records I call RH_UPDATE_DATABASE to commit to database.
My question is that if I am running my program in test mode and I don't call RH_UPDATE_DATABASE, how do I clear the internal buffer that is updated by RH_INSERT_INFTY?
I would appreciate your suggestions.You have to use these two FM together i guess:
1-'RH_CLEAR_BUFFER'.
2- 'RH_CLEAR_PLOG_TAB'.
Check this link for more details:
BAPI_HRMASTER_SAVE_REPL_MULT
Regards
Neha -
hi ,
i want to update the HR table HRP1000 without any transaction code, is it possible, is there any function module to do this, or is there any other way to do this job is yes tell me .....
thanks in advance,
chinnu.pHi
[How to use FM RH_INSERT_INFTY|How to use FM RH_INSERT_INFTY??]
[Sample Example|Re: RH_INSERT_INFTY]
[Sample Example 2 |RH_INSERT_INFTY]
Regards
Pavan -
Hello Community,
Anybody knows if it´s posibble insert field HRP1042-NHOURS in tab "Without pattern"( tr.PP01, Schedule Model) by means of RH_PNNNN_MAINTAIN o whatever other MF, BAPI, class, etc.; not BDC.
With MF RH_PNNNN_MAINTAIN, I achieve create a record in table HRP1042, with field HRP1042-NHOURS filled. But It doesn´t work correctly, because in the transaction PP01, if you select Schedule Model( infotype HRP1042), the field Duration/Hours isn´t filled.
I believe that the problem is caused when I call to MF RH_PNNNN_MAINTAIN, the process always choose 1º option, "With Pattern" of the 3 tabs of the option Schedule Model:
-With Pattern
-Without pattern
- User-defined.
I didn´t see what is the way to choose 2º option in this MF.
Best regards.Hi
I think you can use FM RH_INSERT_INFTY with below parameters for each tabstrip.
Schedule Model with Pattern : Time Schedule of Business Event should be having some value (p1042-AMUST).
Schedule Model Without Pattern : Time Schedule of Business Event should be blank (p1042-AMUST) and p1042-tabnr should be blank.
User defined : Time Schedule of Business Event should be blank (p1042-AMUST) and p1042-tabnr should be having some value.
~~~Ganesh Kumar K. -
Insert Infotype with Table Part
Hi All,
I am trying to insert Infotype nnnn including the information in the table part using a Function Module.
I have found FM RH_INSERT_INFTY_EXP. This FM has a parameter called TNNN which is supposed to hold the table part information. However, I have tried to used this but the table part is not filled.
I saw that PNNNN-ITXNR is relevant here.. However, incremeting this number for each entry I write seems unhandy..
Can anybody help me here?
Thanks, JohannesHi Maricella,
Use FM 'RH_INSERT_INFTY'.
Pass values for below parameters while calling the FM.
REPID = SY-REPID
FORM = 'FILL_TASK_DATA'
Create a subroutine with the same name as you have given above for 'FORM'
and in this subroutine you can populate data for HRTNNNN. -
Unable to create org unit using RH_INSERT_INFTY
All,
We are using internal number range to create Org Units in the SAP System. However, there are some org objects present in a legacy SAP system that we need to upload to the new ECC system and create relationships for them .
Following is my code for the RH_INSERT_INFTY function module :
w1000-mandt = sy-mandt.
w1000-plvar = '01'.
w1000-otype = 'O'.
w1000-OBJID = ''.
w1000-infty = '1000'.
w1000-ISTAT = '1'.
w1000-begda = '20090101'.
w1000-endda = '99991231'.
w1000-langu = 'E'.
w1000-short = 'HR_AST5'.
w1000-stext = 'HR Assistant 5'.
append w1000 to i1000.
CALL FUNCTION 'RH_INSERT_INFTY'
EXPORTING
FCODE = 'INSE'
VTASK = 'S'
ORDER_FLG = 'X'
COMMIT_FLG = 'X'
TABLES
INNNN = i1000
IF SY-SUBRC <> 0.
ENDIF.
I am however unable to create the org units as i get an error saying "Creation of object ID 00000000 is not allowed".
I know im getting this error because im leaving the objid field blank, but I figured since it is internal number range, i would have to give this as blank .
Could somebody please help me figure out how to load these Organizational Objects and their Relationships ?
Thanks,
AmitHi Amit
try to use 'D' as a value of VTASK
or use FM
call function 'RH_OBJECT_CREATE'
exporting
langu = l_langu
plvar = plvar
otype = c_otype
EXT_NUMBER = '00000000' "???
SHORT = ' '
stext = stext
begda = begda
endda = endda
ostat = l_istat
vtask = 'B'
GUID =
KEEP_LUPD = ' '
importing
objid = objid
exceptions
text_required = 1
invalid_otype = 2
invalid_date = 3
error_during_insert = 4
error_ext_number = 5
undefined = 6
others = 7.
In this FM u dont need to pass the Object ID and call function
*---if the above steps are succesful update the database
call function 'RH_UPDATE_DATABASE'
exporting
vtask = vtask
BUFFER_UPD = ' '
ORDER_FLG = 'X'
COMMIT_FLG = 'X'
CLEAR_BUFFER = 'X'
KEEP_LUPD =
WORKF_ACTV = 'X'
exceptions
corr_exit = 1
others = 2 .
as VTASK 'B' will create the entry in buffer and it will only commit to database after the secondFM
or u can try with 'D' as VTASK
Hope this will resolve ur issue
Regards
Guds
Maybe you are looking for
-
I'm going on a hike tomorrow with my dad and I'd been reluctant to download iTunes on my new laptop but finally decided to install it so I could have new music for the trip. I bought nearly ninety new songs, all of which appeared in my library, and
-
IPod not recognised by computer, won't charge + displays sad iPod face
Ok, whenever i attempt to charge my iPod with the mains, it resets itself then shows a sad ipod face. When i connect it to my computer it resets itself, shows the sad face and then sticks on the low battery screen. The "five r's" do absolutly nothing
-
Play WAV files into the .jar
Hello, I'm doing small application Java with Netbeans. I need is to play .wav file sounds are incorporated into the jar. I do not want to use external libraries or external sound files, etc.. I want to go with my .JAR to the office, home, etc ... jus
-
Hello, In our BI 7.0 system, I received the following error in update stats log: BR0301E SQL error -1760 at location stats_tab_collect-16, SQL statement: 'BEGIN DBMS_STATS.GATHER_TABLE_STATS (OWNNAME => '"SAPSR3"', TABNAME => '"/BIC/FZBBP_C03"', PART
-
Whenever I click on somewhere in Safari, I get a message "A keychain cannot be found to store Safari" I can click on an link, or just an empty space on a page. I can cancel, and things seem ok, or I can Reset to Defaults, which I am not sure I want t