cancel
Showing results for 
Search instead for 
Did you mean: 

Error call 'BAPI_ALM_ORDER_MAINTAIN' release order

Former Member
0 Kudos

Hi,

I need to release a PM order with the BAPI:

BAPI_ALM_ORDER_MAINTAIN  with the table T_METHODS

CLEAR T_METHODS.

T_METHODS-REFNUMBER = 1.

T_METHODS-OBJECTTYPE = 'HEADER'.

T_METHODS-METHOD = 'RELEASE'.

T_METHODS-OBJECTKEY = ORDERID.

APPEND T_METHODS.

CLEAR T_METHODS.

T_METHODS-REFNUMBER = 1.

T_METHODS-OBJECTTYPE = ''.

T_METHODS-METHOD = 'SAVE'.

T_METHODS-OBJECTKEY = ORDERID.

APPEND T_METHODS.

CALL FUNCTION 'BAPI_ALM_ORDER_MAINTAIN'

  TABLES

    IT_METHODS              = T_METHODS

 

   RETURN                  = MES.

 

CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'

In result after COMMIT WORK it occurs error. I received letter in mail(SAP Business workplace) with the text : 

"UPDATE_JEST:STATUS_INCONSISTENT: OBJNR: OR003300007364 STATUS: I0115"

Please help me,

regards

Vitaliy

Accepted Solutions (0)

Answers (3)

Answers (3)

raymond_giuseppi
Active Contributor
0 Kudos

try to call method CALCULATE before RELEASE.

Regards,

Raymond

Former Member
0 Kudos

Try method CALCULATE - same result? don't work.

Thre are all statuses my order:

OBJNR                    STAT INACT CHGNR

OR003300007364   E0001            001

OR003300007364   I0001              001

OR003300007364   I0016              001

OR003300007364   I0115      X      007

OR003300007364   I0118      X      001

OR003300007364   I0215               001

OR003300007364   I0420               001

OR003300007364   I0485               001

During exec. it required status I0115 (CSER) must be INACT = space

raymond_giuseppi
Active Contributor
0 Kudos

So there is a problem with your order, did you check back the program which set wronly the cost indicator status ?

Did you try to call transaction IW32, press ctrl+f5 (cost calculate) and check the log ?

Regads,

Raymond

Former Member
0 Kudos

In our system we "hide" operation calculate(disable this operation). In my case I don't have any costs in order? but in tran IW32 when I Release order and press Save I get message

E       KL                   023                                                  1        1

3300007367

No control record for Activity type 1000/110571-36/S008 in version 000 / 2013 activity planning/qty planning

Can this error affect on operation "Release"?

raymond_giuseppi
Active Contributor
0 Kudos

I suppose it disabled update, you should either reactivate cost calculation, even if constraint with release operation, or change standard customizing of system statuses (start from BS22 for status I0115 "Error in cost calculation" or BS32 for operation REL "Release") but this will be a modification, and can be removed by an upgrade or a SP installation.

Regards,

Raymond

Former Member
0 Kudos

Hi Vitaliy,

I think we'll need more information:

-Are you using any custom development/coding in the order e.g. user-exits/BADIs?

-Are the number ranges for the order okay; check transaction SNRO for object AUFTRAG.

-What is the error message class and number? Is it BS 701?

Former Member
0 Kudos

I am using only bapi func module 'BAPI_ALM_ORDER_MAINTAIN' to release existing order.

In transaction SNRO object AUFTRAG : Number range object has intervals.

Error message BS 701.

former_member212002
Active Contributor
0 Kudos

Hello,

I think you have issues with your order.

Check the status tabs of the order and confirm if the status is OK(PLOK).

Cheers!

Abhinab

Former Member
0 Kudos

How can I change the status CSER(Error in cost calculation) in order to make it active?

former_member212002
Active Contributor
0 Kudos

Take help from functional or raise an issue of invalid test data

Former Member
0 Kudos

Hi Vitaliy,

Open the order and see Go to - logs - cost determination, there is a error in cost determination

Thanks

Jey

Former Member
0 Kudos

This problem arise sometimes, two same order can released differently. Error in func module STATUS_UPDATE during the code exec:

LOOP AT jest_ins.
        SELECT SINGLE FOR UPDATE *
               FROM jest CLIENT SPECIFIED
               WHERE mandt = jest_ins-mandt
               AND   objnr = jest_ins-objnr
               AND   stat  = jest_ins-stat.
        IF sy-subrc <> 0.
            INSERT jest FROM jest_ins.
            IF sy-subrc <> 0.
               MESSAGE a700 WITH jest_ins-objnr
                                jest_ins-stat
                                jest_ins-inact.
            ENDIF.
       ELSEIF jest-inact NE jest_ins-inact.
            MESSAGE a701 WITH   jest_ins-objnr
                                jest_ins-stat.
        ENDIF.
      ENDLOOP.

Why compare statuses are different?

Former Member
0 Kudos

I can't open logs cost because it unable (able only Material and PRT availability) May be cause I don't have costs in order