<?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 with excluding material types in a select statement. in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785855#M338470</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Oh, that makes sense.  As I said I have it working but I am not satisfied with the way I got it to work.  However, I'm not sure if using a select statement would work in this case.  I guess I will keep it as is unless somebody gives me a better suggestion.  Thanks to all for your help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 03 Jan 2007 15:49:26 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-01-03T15:49:26Z</dc:date>
    <item>
      <title>Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785845#M338460</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have the following code and I need to exclude material types "WERT" and "PROD" (mara-mtart).  I have a table cmara (mara) but I can't figure out how to exclude them.  I added the code that is in bold (2nd bold group) but I assume where I really need to add this code is what I have in the first bold group.  This code checks to ensure that the material has a correct alternative unit of measure.  If V_FOUND then it does have an alternative unit of measure.  Can somebody tell me if what I did will work (I haven't tested it yet) or better yet if there is a better spot to exclude such material types.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I appreciate any help you can give me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;INCLUDE ZXMG0U02 *&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Dummy change to transport again 1/3/07 as *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;CHANGE TO CREATE TRANSPORT 12/11/2006 SR&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;TABLES: ZBW_REP_INFO, MARM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF I_INFO_TAB OCCURS 0.&lt;/P&gt;&lt;P&gt;INCLUDE STRUCTURE ZBW_REP_INFO.&lt;/P&gt;&lt;P&gt;DATA END OF I_INFO_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF I_AUOM_TAB OCCURS 0.&lt;/P&gt;&lt;P&gt;INCLUDE STRUCTURE MARM.&lt;/P&gt;&lt;P&gt;DATA END OF I_AUOM_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: V_FOUND(1) TYPE C.&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;* I think I should be able to add a condition on the following line to exclude certain material types.&lt;/P&gt;&lt;P&gt;SELECT * FROM ZBW_REP_INFO INTO TABLE I_INFO_TAB.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;if zbw_rep_info-matkl = cmara-matkl and&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;zbw_rep_info-meinh = cmara-meins.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;exit.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;CLEAR V_FOUND.&lt;/P&gt;&lt;P&gt;LOOP AT I_INFO_TAB.&lt;/P&gt;&lt;P&gt;IF I_INFO_TAB-MATKL = CMARA-MATKL AND&lt;/P&gt;&lt;P&gt;I_INFO_TAB-MEINH = CMARA-MEINS.&lt;/P&gt;&lt;P&gt;V_FOUND = 'X'.&lt;/P&gt;&lt;P&gt;EXIT.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;* AS - 1/3/07&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Added to exclude material types "WERT" and "PROD"&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;IF I_INFO_TAB-MATKL = CMARA-MATKL AND I_INFO_TAB-MEINH = CMARA-MEINS AND CMARA-MTART = 'WERT'.&lt;/P&gt;&lt;P&gt;V_FOUND = 'X'.&lt;/P&gt;&lt;P&gt;EXIT.&lt;/P&gt;&lt;P&gt;ELSEIF I_INFO_TAB-MATKL = CMARA-MATKL AND I_INFO_TAB-MEINH = CMARA-MEINS AND CMARA-MTART = 'PROD'.&lt;/P&gt;&lt;P&gt;V_FOUND = 'X'.&lt;/P&gt;&lt;P&gt;EXIT.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;End of change on 1/3/07&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF V_FOUND IS INITIAL.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;select * from marm into table i_auom_tab&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;where matnr = cmara-matnr.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;clear v_found.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;loop at i_auom_tab.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;if i_auom_tab-matnr = cmara-matnr and&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;i_auom_tab-meinh = cmara-meins.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;v_found = 'X'.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;exit.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;SELECT SINGLE * FROM ZBW_REP_INFO WHERE MATKL = CMARA-MATKL.&lt;/P&gt;&lt;P&gt;LOOP AT WMEINH.&lt;/P&gt;&lt;P&gt;IF WMEINH-MEINH = ZBW_REP_INFO-MEINH.&lt;/P&gt;&lt;P&gt;V_FOUND = 'X'.&lt;/P&gt;&lt;P&gt;EXIT.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;IF V_FOUND IS INITIAL.&lt;/P&gt;&lt;P&gt;MESSAGE E001(Z1).&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 14:25:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785845#M338460</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T14:25:18Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785846#M338461</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;SELECT * FROM ZBW_REP_INFO INTO TABLE I_INFO_TAB
               where MTART &amp;lt;&amp;gt; 'PROD' 
                   and MTART &amp;lt;&amp;gt; 'WERT'.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 14:40:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785846#M338461</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2007-01-03T14:40:06Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785847#M338462</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Will this work even though ZBW_REP_INFO does not have MTART as a field?  It only has MANDT, MATKL, and MEINH.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Aaron&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 14:42:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785847#M338462</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T14:42:04Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785848#M338463</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi shover,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CHECK out this code:the functionality can be acheived with two selects or with one select.&lt;/P&gt;&lt;P&gt;oneselect : using join&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * INTO TABLE I_INFO_TAB from ZBW_REP_INFO as A join Mara as B&lt;/P&gt;&lt;P&gt;on A&lt;SUB&gt;MATKL = B&lt;/SUB&gt;-MATKL AND A&lt;SUB&gt;MEINH = B&lt;/SUB&gt;MEINS  where mtart &amp;lt;&amp;gt; 'WERT' and 'PROD'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;two selects:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * from mara into table cmara where mtart &amp;lt;&amp;gt; 'WERT' and 'PROD'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * FROM ZBW_REP_INFO INTO TABLE I_INFO_TAB&lt;/P&gt;&lt;P&gt; FOR ALL ENTRIES IN CMARA WHERE&lt;/P&gt;&lt;P&gt;MATKL = CMARA-MATKL AND MEINH = CMARA-MEINS .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;plese check out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sateesh.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 14:43:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785848#M338463</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T14:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785849#M338464</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If there is no MTART in your custom table, then you will need to join to MARA,  bu where is MATNR? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REgards,&lt;/P&gt;&lt;P&gt;RIch Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 14:56:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785849#M338464</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2007-01-03T14:56:14Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785850#M338465</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;matnr is not being used.  I am seeing this user exit for the first time so I'm not sure why but it was used then commented out.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 15:16:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785850#M338465</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T15:16:07Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785851#M338466</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;sateesh, thanks for your reply.  It seems like what you posted, using the join, will work but I get an error when I do a syntax check on it.  I get an error saying that "The work area I_INFO_TAB is not long enough."  I was going to try the solution with two selects but I assume that it would be better to use one instead of two.  Followed is the code that I have working but I assume that it would be better to exclude them from the select, which is why I would like to better understand your join example.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Aaron&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  INCLUDE ZXMG0U02                                                   *&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  Dummy change to transport again 1/3/07 as                          *&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;CHANGE TO CREATE TRANSPORT  12/11/2006 SR&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;TABLES: ZBW_REP_INFO, MARM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF I_INFO_TAB OCCURS 0.&lt;/P&gt;&lt;P&gt;        INCLUDE STRUCTURE ZBW_REP_INFO.&lt;/P&gt;&lt;P&gt;DATA END OF I_INFO_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF I_AUOM_TAB OCCURS 0.&lt;/P&gt;&lt;P&gt;        INCLUDE STRUCTURE MARM.&lt;/P&gt;&lt;P&gt;DATA END OF I_AUOM_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: V_FOUND(1) TYPE C.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * FROM ZBW_REP_INFO INTO TABLE I_INFO_TAB.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;if zbw_rep_info-matkl = cmara-matkl and&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   zbw_rep_info-meinh = cmara-meins.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   exit.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;CLEAR V_FOUND.&lt;/P&gt;&lt;P&gt;LOOP AT I_INFO_TAB.&lt;/P&gt;&lt;P&gt;  IF I_INFO_TAB-MATKL = CMARA-MATKL AND&lt;/P&gt;&lt;P&gt;     I_INFO_TAB-MEINH = CMARA-MEINS.&lt;/P&gt;&lt;P&gt;    V_FOUND = 'X'.&lt;/P&gt;&lt;P&gt;    EXIT.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;* AS - 1/3/07&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Added to exclude material types "WERT" and "PROD"&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  IF CMARA-MTART = 'WERT'.&lt;/P&gt;&lt;P&gt;    V_FOUND = 'X'.&lt;/P&gt;&lt;P&gt;    EXIT.&lt;/P&gt;&lt;P&gt;  ELSEIF CMARA-MTART = 'PROD'.&lt;/P&gt;&lt;P&gt;    V_FOUND = 'X'.&lt;/P&gt;&lt;P&gt;    EXIT.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;End of change on 1/3/07&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF V_FOUND IS INITIAL.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  select * from marm into table i_auom_tab&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    where matnr = cmara-matnr.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  clear v_found.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;loop at i_auom_tab.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  if i_auom_tab-matnr = cmara-matnr and&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;     i_auom_tab-meinh = cmara-meins.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;      v_found = 'X'.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;     exit.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; endif.&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; endloop.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  SELECT SINGLE * FROM ZBW_REP_INFO WHERE MATKL = CMARA-MATKL.&lt;/P&gt;&lt;P&gt;  LOOP AT WMEINH.&lt;/P&gt;&lt;P&gt;    IF WMEINH-MEINH = ZBW_REP_INFO-MEINH.&lt;/P&gt;&lt;P&gt;      V_FOUND = 'X'.&lt;/P&gt;&lt;P&gt;      EXIT.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;  ENDLOOP.&lt;/P&gt;&lt;P&gt;  IF V_FOUND IS INITIAL.&lt;/P&gt;&lt;P&gt;    MESSAGE E001(Z1).&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 15:22:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785851#M338466</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T15:22:20Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785852#M338467</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Shover,&lt;/P&gt;&lt;P&gt;In the select with join i mentioned * . You define an internal table  I_INFO_TAB with  required fields and give the same fields in sequence in the select statement instead of '*'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check out ..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sateesh.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 15:33:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785852#M338467</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T15:33:09Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785853#M338468</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Like this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT "mandt" "matkl" "meinh" INTO TABLE I_INFO_TAB FROM ZBW_REP_INFO AS A JOIN MARA AS B&lt;/P&gt;&lt;P&gt;ON A&lt;SUB&gt;mandt = B&lt;/SUB&gt;mandt and A&lt;SUB&gt;MATKL = B&lt;/SUB&gt;MATKL AND A&lt;SUB&gt;MEINH = B&lt;/SUB&gt;MEINS WHERE MTART &amp;lt;&amp;gt; 'WERT' AND 'PROD'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm sorry, I a very beginner ABAPer so this may be elementary.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Aaron&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 15:42:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785853#M338468</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T15:42:04Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785854#M338469</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The problem here is that MATKL is not part of the key and therefore will give inconsistant results.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 15:43:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785854#M338469</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2007-01-03T15:43:50Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785855#M338470</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Oh, that makes sense.  As I said I have it working but I am not satisfied with the way I got it to work.  However, I'm not sure if using a select statement would work in this case.  I guess I will keep it as is unless somebody gives me a better suggestion.  Thanks to all for your help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 15:49:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785855#M338470</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T15:49:26Z</dc:date>
    </item>
    <item>
      <title>Re: Help with excluding material types in a select statement.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785856#M338471</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have it working but I am not satisfied with the way I got it to work.  However, I'm not sure if using a select statement would work in this case.  I guess I will keep it as is unless somebody gives me a better suggestion.  Thanks to all for your help!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Jan 2007 15:50:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/help-with-excluding-material-types-in-a-select-statement/m-p/1785856#M338471</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-01-03T15:50:47Z</dc:date>
    </item>
  </channel>
</rss>

