<?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: help in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599800#M269339</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sowjanya,&lt;/P&gt;&lt;P&gt;Thankx.&lt;/P&gt;&lt;P&gt;Actuall the whole description is given as below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3.	Sub-Step (a)	&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For all the records that survived step 2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT all the records from A903 where&lt;/P&gt;&lt;P&gt;	    KAPPL in S_KAPPL&lt;/P&gt;&lt;P&gt;	AND KSCHL in S_KSCHL&lt;/P&gt;&lt;P&gt;	AND VKORG in S_VKORG&lt;/P&gt;&lt;P&gt;	AND VTWEG in S_VTWEG&lt;/P&gt;&lt;P&gt;	AND PLTYP in S_PLTYP&lt;/P&gt;&lt;P&gt;	AND KFRST in S_KFRST&lt;/P&gt;&lt;P&gt;	AND KNUMH = CDHDR-OBJECTID (saved in step 2)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF there are multiple records (unlikely, but &amp;#133;) take ONLY the one with the highest end date (DATBI).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sub-Step (b)	&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For each record selected in Sub-Step (a)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT the field KBETR from KONP where&lt;/P&gt;&lt;P&gt;	    KNUMH = A903-KNUMH&lt;/P&gt;&lt;P&gt;	AND KOPOS = 1	&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Only the condition price (KBETR) is retrieved from this table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sub-Step (c)	GET the NDC-11 for the material&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For each record selected in Sub-Step (a)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT the field BISMT (Old Material Number) from MARA where&lt;/P&gt;&lt;P&gt;	    MATNR = A903-MATNR&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF found&lt;/P&gt;&lt;P&gt;THEN&lt;/P&gt;&lt;P&gt;	This is the material number for the output record; REMOVE THE DASHES before exporting.&lt;/P&gt;&lt;P&gt;ELSE&lt;/P&gt;&lt;P&gt;	Create an entry in an internal table for the validation report; the entry should lists all the details required by the export file and the fact that no &amp;#147;Old Material Number&amp;#148; = &amp;#147;NDC-11&amp;#148; was found.&lt;/P&gt;&lt;P&gt;ENDIF&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can u help to write the code for the above  description.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;siri.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 11 Sep 2006 10:03:09 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-09-11T10:03:09Z</dc:date>
    <item>
      <title>help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599796#M269335</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi friends,&lt;/P&gt;&lt;P&gt;plz help me to code for the below description.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sub-Step (b)	GET the price for the material&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For each record selected in Sub-Step (a)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT the field KBETR from KONP where&lt;/P&gt;&lt;P&gt;	    KNUMH = A903-KNUMH&lt;/P&gt;&lt;P&gt;	AND KOPOS = 1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;siri..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 09:31:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599796#M269335</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-11T09:31:27Z</dc:date>
    </item>
    <item>
      <title>Re: help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599797#M269336</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data:begin of itab2 occurs 0,&lt;/P&gt;&lt;P&gt;kbetr like konp-kbetr,&lt;/P&gt;&lt;P&gt;bomat like konp-bomat,&lt;/P&gt;&lt;P&gt;knumh like konp-knumh,&lt;/P&gt;&lt;P&gt;kopos like konp-kopos,&lt;/P&gt;&lt;P&gt;end of itab2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select kbetr bomat knumh kopos &lt;/P&gt;&lt;P&gt;from konp&lt;/P&gt;&lt;P&gt;into table itab2&lt;/P&gt;&lt;P&gt; for all entires in itab1&lt;/P&gt;&lt;P&gt; where bomat = itab1-matnr and&amp;lt;b&amp;gt; &amp;lt;&amp;lt; for each material selected in substep(a)&amp;gt;&amp;gt;&amp;lt;/b&amp;gt; &lt;/P&gt;&lt;P&gt;knumh = a903-knumh and&lt;/P&gt;&lt;P&gt;kopos = 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;sowjanya.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: sowjanya suggula&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 09:36:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599797#M269336</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-11T09:36:03Z</dc:date>
    </item>
    <item>
      <title>Re: help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599798#M269337</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; SELECT  a&lt;SUB&gt;matreila s&lt;/SUB&gt;price&lt;/P&gt;&lt;P&gt;              &lt;/P&gt;&lt;P&gt;                INTO TABEL INT_material_name_price&lt;/P&gt;&lt;P&gt;                  FROM table_name AS a&lt;/P&gt;&lt;P&gt;                    INNER JOIN&lt;/P&gt;&lt;P&gt;                      tabel_price AS s&lt;/P&gt;&lt;P&gt;                        ON  a&lt;SUB&gt;matrialID = s&lt;/SUB&gt;matrialID.&lt;/P&gt;&lt;P&gt;           &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for any clarifiaction pls mail me.&lt;/P&gt;&lt;P&gt;pls reward points, if this helped u.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;anversha.&lt;/P&gt;&lt;P&gt;anversha.shahul@wipro.com&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 09:37:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599798#M269337</guid>
      <dc:creator>anversha_s</dc:creator>
      <dc:date>2006-09-11T09:37:40Z</dc:date>
    </item>
    <item>
      <title>Re: help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599799#M269338</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if lines( &amp;lt;ITAB_TEMP&amp;gt; ) &amp;gt; 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  select kbetr from knop into table &amp;lt;ITAB2&amp;gt;&lt;/P&gt;&lt;P&gt;   for all entires in &amp;lt;ITAB_TEMP&amp;gt;&lt;/P&gt;&lt;P&gt;    where KNUMH = &amp;lt;ITAB_TEMP&amp;gt;-KNUMH and&lt;/P&gt;&lt;P&gt;          PRSCH = &amp;lt;ITAB_TEMP&amp;gt;-KBETR and&lt;/P&gt;&lt;P&gt;          KOPOS = 1.&lt;/P&gt;&lt;P&gt;  if sy-subrc EQ 0.  &lt;/P&gt;&lt;P&gt;     sort &amp;lt;ITAB2&amp;gt; by knumh.&lt;/P&gt;&lt;P&gt;  endif.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regs,&lt;/P&gt;&lt;P&gt;Venkat Ramanan N&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 09:40:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599799#M269338</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-11T09:40:23Z</dc:date>
    </item>
    <item>
      <title>Re: help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599800#M269339</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sowjanya,&lt;/P&gt;&lt;P&gt;Thankx.&lt;/P&gt;&lt;P&gt;Actuall the whole description is given as below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3.	Sub-Step (a)	&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For all the records that survived step 2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT all the records from A903 where&lt;/P&gt;&lt;P&gt;	    KAPPL in S_KAPPL&lt;/P&gt;&lt;P&gt;	AND KSCHL in S_KSCHL&lt;/P&gt;&lt;P&gt;	AND VKORG in S_VKORG&lt;/P&gt;&lt;P&gt;	AND VTWEG in S_VTWEG&lt;/P&gt;&lt;P&gt;	AND PLTYP in S_PLTYP&lt;/P&gt;&lt;P&gt;	AND KFRST in S_KFRST&lt;/P&gt;&lt;P&gt;	AND KNUMH = CDHDR-OBJECTID (saved in step 2)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF there are multiple records (unlikely, but &amp;#133;) take ONLY the one with the highest end date (DATBI).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sub-Step (b)	&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For each record selected in Sub-Step (a)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT the field KBETR from KONP where&lt;/P&gt;&lt;P&gt;	    KNUMH = A903-KNUMH&lt;/P&gt;&lt;P&gt;	AND KOPOS = 1	&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Only the condition price (KBETR) is retrieved from this table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sub-Step (c)	GET the NDC-11 for the material&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For each record selected in Sub-Step (a)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT the field BISMT (Old Material Number) from MARA where&lt;/P&gt;&lt;P&gt;	    MATNR = A903-MATNR&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF found&lt;/P&gt;&lt;P&gt;THEN&lt;/P&gt;&lt;P&gt;	This is the material number for the output record; REMOVE THE DASHES before exporting.&lt;/P&gt;&lt;P&gt;ELSE&lt;/P&gt;&lt;P&gt;	Create an entry in an internal table for the validation report; the entry should lists all the details required by the export file and the fact that no &amp;#147;Old Material Number&amp;#148; = &amp;#147;NDC-11&amp;#148; was found.&lt;/P&gt;&lt;P&gt;ENDIF&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;can u help to write the code for the above  description.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;siri.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 10:03:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599800#M269339</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-11T10:03:09Z</dc:date>
    </item>
    <item>
      <title>Re: help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599801#M269340</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SELECT * into table ia903 from A903&lt;/P&gt;&lt;P&gt;where KAPPL in S_KAPPL&lt;/P&gt;&lt;P&gt;AND KSCHL in S_KSCHL&lt;/P&gt;&lt;P&gt;AND VKORG in S_VKORG&lt;/P&gt;&lt;P&gt;AND VTWEG in S_VTWEG&lt;/P&gt;&lt;P&gt;AND PLTYP in S_PLTYP&lt;/P&gt;&lt;P&gt;AND KFRST in S_KFRST&lt;/P&gt;&lt;P&gt;AND KNUMH = CDHDR-OBJECTID.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort ia903 by knumh.&lt;/P&gt;&lt;P&gt;SELECT knumh KBETR into table ikonp from KONP &lt;/P&gt;&lt;P&gt;for all entries in ia903&lt;/P&gt;&lt;P&gt;where KNUMH = iA903-KNUMH&lt;/P&gt;&lt;P&gt;AND KOPOS = 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort ia903 by matnr.&lt;/P&gt;&lt;P&gt;SELECT MATNR BISMT into imara &lt;/P&gt;&lt;P&gt;from MARA for all entries in ia903&lt;/P&gt;&lt;P&gt;where MATNR = A903-MATNR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sort ia903 by key fields + datbi descending.&lt;/P&gt;&lt;P&gt;Loop at ia903.&lt;/P&gt;&lt;P&gt;  at new key field.&lt;/P&gt;&lt;P&gt;     clear imara.&lt;/P&gt;&lt;P&gt;     read table imara with key matnr = ia903-matnr.&lt;/P&gt;&lt;P&gt;     if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;        translate imara-matnr using '- '.&lt;/P&gt;&lt;P&gt;        condense imara-matnr no-gap.&lt;/P&gt;&lt;P&gt;     ELSE&lt;/P&gt;&lt;P&gt;Create an entry in an internal table for the validation report; the entry should lists all the details required by the export file and the fact that no &amp;#147;Old Material Number&amp;#148; = &amp;#147;NDC-11&amp;#148; was found.&lt;/P&gt;&lt;P&gt;     endif.&lt;/P&gt;&lt;P&gt;  endat.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Anurag&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 10:15:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599801#M269340</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-11T10:15:43Z</dc:date>
    </item>
    <item>
      <title>Re: help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599802#M269341</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi Anurag,&lt;/P&gt;&lt;P&gt;thanx.&lt;/P&gt;&lt;P&gt;what is the meaning of this then.&lt;/P&gt;&lt;P&gt;plz help me with this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;ELSE&lt;/P&gt;&lt;P&gt;Create an entry in an internal table for the validation report; the entry should lists all the details required by the export file and the fact that no &amp;#147;Old Material Number&amp;#148; = &amp;#147;NDC-11&amp;#148; was found.&lt;/P&gt;&lt;P&gt;endif.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;siri.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 10:18:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599802#M269341</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-11T10:18:07Z</dc:date>
    </item>
    <item>
      <title>Re: help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599803#M269342</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As per you specification..you need to write the particular information into an internal table. So the code to populate the internal table should be written there..as I am not sure of the structure etc of the validation report ..I did just paste the text.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in short.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;  clear ivalidationreport.&lt;/P&gt;&lt;P&gt;  move imara-matnr to ivalidationreport-matnr.&lt;/P&gt;&lt;P&gt;  move 'Old Material Number = NDC-11 not found to ivalidatreport-remarks.&lt;/P&gt;&lt;P&gt;  append ivalidationreport.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--ivalidationreport is the validation report internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Anurag&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please assign points for helpful answers !!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 10:22:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599803#M269342</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-11T10:22:30Z</dc:date>
    </item>
    <item>
      <title>Re: help</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599804#M269343</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sireesha,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * from a903&lt;/P&gt;&lt;P&gt;into table itab&lt;/P&gt;&lt;P&gt;where KAPPL in S_KAPPL&lt;/P&gt;&lt;P&gt;AND KSCHL in S_KSCHL&lt;/P&gt;&lt;P&gt;AND VKORG in S_VKORG&lt;/P&gt;&lt;P&gt;AND VTWEG in S_VTWEG&lt;/P&gt;&lt;P&gt;AND PLTYP in S_PLTYP&lt;/P&gt;&lt;P&gt;AND KFRST in S_KFRST&lt;/P&gt;&lt;P&gt;AND KNUMH = CDHDR-OBJECTID.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;describe table itab lines ln.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if ln &amp;gt; 1.  &amp;lt;b&amp;gt;&amp;lt;&amp;lt; in case of more than one record&amp;gt;&amp;gt;&amp;lt;/b&amp;gt;sort itab by datbi descending.&lt;/P&gt;&lt;P&gt;read table itab index 1.&lt;/P&gt;&lt;P&gt;move itab-datbi to itab2-datbi.&lt;/P&gt;&lt;P&gt;append itab2.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select kbetr from konp&lt;/P&gt;&lt;P&gt;into table itab3&lt;/P&gt;&lt;P&gt;for all entires in itab1&lt;/P&gt;&lt;P&gt;where knumh = itab1-knumh and&lt;/P&gt;&lt;P&gt;kopos = 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select bismt from mara&lt;/P&gt;&lt;P&gt;into table itab4&lt;/P&gt;&lt;P&gt;for all entries in itab1&lt;/P&gt;&lt;P&gt;where matnr = itab1-matnr.&lt;/P&gt;&lt;P&gt; if sy-subrc = 0. &amp;lt;b&amp;gt;&amp;lt;&amp;lt;remove '-'s in the matnr&amp;gt;&amp;gt;&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt; translate itab4-matnr using '- '.&lt;/P&gt;&lt;P&gt;condense itab4-matnr no-gap.&lt;/P&gt;&lt;P&gt; else.&lt;/P&gt;&lt;P&gt; write:/ "no material found with',itab4-matnr.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sowjanya.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Sep 2006 10:32:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help/m-p/1599804#M269343</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-11T10:32:10Z</dc:date>
    </item>
  </channel>
</rss>

