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

how to update EBAN-BLCKD using bapi?

sahai
Contributor
0 Likes
2,804

hi experts,

i have to change the EBAN-BLCKD field of a PR to unblock it...i am using bapi_requisition_change to acheive it.

kindly help me with code to achieve it.

thanks and regards,

shitanshu sahai

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,748

Hi,

Check with the SAP Standard Program 'RBUS2105'


CALL FUNCTION 'BAPI_REQUISITION_CHANGE'
EXPORTING
number = object-key-number
TABLES
return = return
requisition_text_new = requisitiontextnew
requisition_text_old = requisitiontextold
requisition_account_new = requisitionaccountne
requisition_account_old = requisitionaccountol
requisition_items_new = requisitionitemsnew
requisition_items_old = requisitionitemsold
EXCEPTIONS
OTHERS = 01.

Try it out.

Thanks

Arbind

hi experts,

i have to change the EBAN-BLCKD field of a PR to unblock it...i am using bapi_requisition_change to acheive it.

kindly help me with code to achieve it.

thanks and regards,

shitanshu sahai

6 REPLIES 6
Read only

Former Member
0 Likes
1,748

Hi shitanshu sahai

You can try this.

Since you do not have option to provide EBAN-BLCKD in the BAPI.

*You can try for implement IMPLICIT Enhancement point inside the peform requisition_change_data.

Implement in the begin of the FORM Routine

PERFORM requisition_change_data TABLES xebkn

requisition_text_old

requisition_text_new

return

xeban.*

Regards

Madhan D

Read only

0 Likes
1,748

hi Madhan Doraikannan ,

can you please elaborate a bit......exactly what i should i do to achieve my aim

regards,

sahai.s

Read only

0 Likes
1,748

Hi

I hope you are using SAP ECC system

if yes

Then open the routine PERFORM requisition_change_data

(1) Click on the SPIRAL Button or SHIFT+F4

(2) EDIT -> Enhancement Operations ->Show Implicit Enhancement options

(3) You can see something in yellow Colour """"""""""""$"$\SE:(17 ) Form REQUISITION_CHANGE_DATA, Start

(4) Place the cusor - Right click - Enhancment Implementation->Create

(5) You will get a popup message with "Declartion" "Code" "Cancel"

(6) Choose Code

(7) You will get one more pop up, with list of Enhancement implementation

(8) Click on Create Button or F8

(9) You will get one more popup to enter the Enhancement Implementation with short text ( Give ZXXXX and Desc), click on Green arrow button

(10) It will get added in the enhancement list

(11) Choose the Z enhancement, Click on Green arrow button

(12) You will get the option, to write your own custom code

Based on the business logic, pass EBAN-BLCKD = 'X'.

Please note this is only the assumption that it may work.

What i suggest, keep a break point near the subroutine requisition_change_data and in the debug pass EBAN-BLCKD = 'X', if you get desired result.

Then obviously the IMPLICIT ENHANCEMENT OPTION will work

Regards

Madhan D

Read only

Former Member
0 Likes
1,749

Hi,

Check with the SAP Standard Program 'RBUS2105'


CALL FUNCTION 'BAPI_REQUISITION_CHANGE'
EXPORTING
number = object-key-number
TABLES
return = return
requisition_text_new = requisitiontextnew
requisition_text_old = requisitiontextold
requisition_account_new = requisitionaccountne
requisition_account_old = requisitionaccountol
requisition_items_new = requisitionitemsnew
requisition_items_old = requisitionitemsold
EXCEPTIONS
OTHERS = 01.

Try it out.

Thanks

Arbind

Read only

Former Member
0 Likes
1,748

What version are you using? Did you try out the BAPI_PR_CHANGE (it seems to have REQ_BLOCKED field in PRITEM table)... This bapi does not exist in 4.6C

Read only

PatrickDean
Participant
0 Likes
1,748

I know it's not a BAPI, but I found  FMFG_MM_REQ_CHANGE to do the job.

It also saves the hassle of doing all the EXTENSIONIN stuff, as it's got EBAN's extension fields in it's MEREQ_ITEM structure.