Skip to Content
author's profile photo Former Member
Former Member

BAPI Modify result lot inspection

hi people...

i must modify results for a lot inspection... i dont know how do it.

i use BAPI_INSPCHAR_SETRESULT for insert new result......but i dont know how modify a result that have been insert before.

please, i need an example about how to use that BAPI to modify, or other BAPI or FM.

thxz bye..

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Sep 20, 2007 at 04:01 PM

    This BAPI should work to modify the data however this is obsolete. Please check these threads. This will help you to use BAPI_INSOPER_RECORDRESULTS which is a replacement of BAPI_INSPCHAR_SETRESULT.

    http://abap.wikiprog.com/wiki/BAPI_INSPCHAR_SETRESULT

    bapiinspoperrecordresults-record-insp-lot-results

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 20, 2007 at 04:04 PM

    sorry this is the bapi that i use BAPI_INSPOPER_RECORDRESULTS

    but i dont know how modify result for a lot inspection

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Here is the sample code, let me know if this helps -

      DATA: BEGIN OF ichar_results OCCURS 0.

      INCLUDE STRUCTURE BAPI2045D2.

      DATA: END OF ichar_results.

      DATA: BEGIN OF isingle_results OCCURS 0.

      INCLUDE STRUCTURE BAPI2045D4.

      DATA: END OF isingle_results.

      DATA: BEGIN OF bapireturn2 OCCURS 0.

      INCLUDE STRUCTURE bapiret2.

      DATA: END OF bapireturn2.

      isingle_results-insplot = '70000009550'.

      isingle_results-inspoper = '0010'.

      isingle_results-inspchar = '0010'.

      isingle_results-res_value = '1.65'.

      isingle_results-res_no = '0001'.

      APPEND isingle_results.

      ichar_results-insplot = '70000009550'.

      ichar_results-inspoper = '0010'.

      ichar_results-inspchar = '0010'.

      ichar_results-closed = 'X'.

      ichar_results-evaluated = 'X'.

      ichar_results-evaluation = 'A'.

      APPEND ichar_results.

      CALL FUNCTION 'BAPI_INSPOPER_RECORDRESULTS'

      EXPORTING

      INSPLOT = '70000009550'

      INSPOPER = '0010'

      IMPORTING

      RETURN = bapireturn2

      TABLES

      CHAR_RESULTS = ichar_results

      SINGLE_RESULTS = isingle_results.

      CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'

      EXPORTING

      WAIT = 'X'

      IMPORTING

      RETURN = bapireturn2.

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.