<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: BAPI - CSAI_BOM_CREATE  error in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-csai-bom-create-error/m-p/7843391#M1591144</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rob sir,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks for Updating me.,  I saw that report., this is what i used in my program., but difference is I am creating Equipment BOM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any other Suggestions... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And the Strange thing is ., It is working and BOM is creating in IDES., but while coming to DEV., sy-subrc = 1. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; regards,&lt;/P&gt;&lt;P&gt;Kiran&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 20 May 2011 16:24:08 GMT</pubDate>
    <dc:creator>Kiran_Valluru</dc:creator>
    <dc:date>2011-05-20T16:24:08Z</dc:date>
    <item>
      <title>BAPI - CSAI_BOM_CREATE  error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-csai-bom-create-error/m-p/7843389#M1591142</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Experts.,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I created a report  for uploading BOM equipments using BAPI - &lt;STRONG&gt;CSAI_BOM_CREATE&lt;/STRONG&gt; . &lt;STRONG&gt;It is working fine in IDES System , but when I used the same in DEV System It is Giving Error.&lt;/STRONG&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;below is my code.,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;LOOP AT IT_FINAL INTO wa_final.

 WA_FINAL1 = WA_FINAL.

  at new equnr.

cLEAR wa_csin.
CLEAR: count, itm_no, cnt.
* wa_csin-aennr = '009900159470'.
wa_csin-datuv = sy-datum.
wa_csin-equnr = WA_FINAL1-equnr.
wa_csin-werks = WA_FINAL1-werks.
wa_csin-stlan = WA_FINAL1-stlan.  " 4
wa_csin-stlty = 'E'.
*wa_csin-werks = '1000'.

CLEAR wa_stkob.
wa_stkob-stlty = 'E'.

CLEAR wa_stzub.
wa_stzub-stlty = 'E'.

 cnt = 10.

 ENDAT.

 count = cnt.

 IF cnt &amp;lt; 100.

 CONCATENATE '00' count INTO itm_no.

 ELSE.

 CONCATENATE '0' count INTO itm_no.


 ENDIF.


CLEAR wa_stpob.
wa_stpob-stlty = 'E'.
wa_stpob-idnrk = WA_FINAL1-idnrk.
wa_stpob-postp = 'I'.
wa_stpob-posnr = itm_no.
wa_stpob-menge = WA_FINAL1-menge.
wa_stpob-potx1 = WA_FINAL1-potx1.
wa_stpob-potx2 = WA_FINAL1-potx2.
wa_stpob-datuv = sy-datum.
APPEND wa_stpob TO tab_stpob.
CLEAR wa_stpob.


at END OF equnr.

CALL FUNCTION 'CSAI_BOM_CREATE'
  EXPORTING
    ecsin = wa_csin
    estkob = wa_stkob
    estzub = wa_stzub
  IMPORTING
    fl_warning = g_flwarning
    astlnr = g_warn_stlnr
  TABLES
    t_stpob = tab_stpob
  EXCEPTIONS
    error = 1
    OTHERS = 2.


IF sy-subrc NE 0.   " here Sy-subrc is 1

* error msg

ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the above code is working fine in IDES., not in DEV., sy-subrc returns 1. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I Debugged and checked in BAPI., the FM  &lt;STRONG&gt;CS_DI_ITEM_CHECK is returning error&lt;/STRONG&gt;.  "{ Terminate if API log contains error    "messages }&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please tell Why the error is occuring.!! what need to be changed..!!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kiran&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 May 2011 15:36:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-csai-bom-create-error/m-p/7843389#M1591142</guid>
      <dc:creator>Kiran_Valluru</dc:creator>
      <dc:date>2011-05-20T15:36:30Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI - CSAI_BOM_CREATE  error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-csai-bom-create-error/m-p/7843390#M1591143</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, it's not a BAPI; however, there may be something in program RJSDBOMTEST that will help you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 May 2011 15:44:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-csai-bom-create-error/m-p/7843390#M1591143</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-05-20T15:44:58Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI - CSAI_BOM_CREATE  error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-csai-bom-create-error/m-p/7843391#M1591144</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rob sir,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks for Updating me.,  I saw that report., this is what i used in my program., but difference is I am creating Equipment BOM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any other Suggestions... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And the Strange thing is ., It is working and BOM is creating in IDES., but while coming to DEV., sy-subrc = 1. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; regards,&lt;/P&gt;&lt;P&gt;Kiran&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 May 2011 16:24:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-csai-bom-create-error/m-p/7843391#M1591144</guid>
      <dc:creator>Kiran_Valluru</dc:creator>
      <dc:date>2011-05-20T16:24:08Z</dc:date>
    </item>
  </channel>
</rss>

