<?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: Performance Issue with MSEG in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502859#M1654227</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What happens when you remove the JOIN mentioned in Page 6 of SAP Note 1293807???  Does the performance get noticeably worse?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Che&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 23 Feb 2012 14:43:59 GMT</pubDate>
    <dc:creator>che_eky</dc:creator>
    <dc:date>2012-02-23T14:43:59Z</dc:date>
    <item>
      <title>Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502844#M1654212</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have a report having below logic.it is taking long time to fetch data from dictionary.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
    SELECT
     KT~MBLNR  "NUMBER OF MATERIAL DOCUMENT
     KT~MJAHR  "MATERIAL DOCUMENT YEAR
     KT~BUDAT  "POSTING DATE IN THE DOCUMENT
     ST~ZEILE  "ITEM IN MATERIAL DOCUMENT
     ST~BWART  "MOVEMENT TYPE (INVENTORY MANAGEMENT)
     ST~MATNR  "MATERIAL NUMBER
     ST~WERKS  "PLANT
     ST~LGORT  "STORAGE LOCATION
     ST~CHARG  "BATCH NUMBER
     ST~SHKZG  "DEBIT/CREDIT INDICATOR
     ST~MENGE  "QUANTITY
     ST~BUKRS  "COMPANY CODE
     ST~OIVBELN " DELIVERY NO
     ST~OIPOSNR
INTO CORRESPONDING FIELDS OF TABLE GIT_MKPFMSEG_P
FROM
    ( ( (
    MKPF AS KI INNER JOIN
    MSEG AS SI ON
    KI~MANDT = SI~MANDT AND
    KI~MBLNR = SI~MBLNR AND
    KI~MJAHR = SI~MJAHR ) INNER JOIN
    MKPF AS KT ON
    KI~MANDT = KT~MANDT AND
    KI~MBLNR = KT~MBLNR AND
    KI~MJAHR = KT~MJAHR ) INNER JOIN
    MSEG AS ST ON
    SI~MANDT = ST~MANDT AND
    SI~MBLNR = ST~MBLNR AND
    SI~MJAHR = ST~MJAHR AND
    SI~ZEILE = ST~ZEILE )
    WHERE
         KI~BUDAT IN S_DATE
    AND  SI~MATNR EQ GWA_MARD-MATNR
    AND  SI~WERKS EQ GWA_MARD-WERKS
    AND  SI~LGORT EQ GWA_MARD-LGORT
    %_HINTS ORACLE 'INDEX(u201CMSEGu201D u201CMSEG~Mu201D)'.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have gone through all most all SDN forum posts related to &lt;STRONG&gt;MSEG&lt;/STRONG&gt; slowness issue and followed everything in code.for me, no INDEX is required as it is using internally standard SAP INDEX &lt;STRONG&gt;M&lt;/STRONG&gt; while scanning. along with that, I have also forced it inside my &lt;STRONG&gt;WHERE&lt;/STRONG&gt; clause for some hope.The above &lt;STRONG&gt;JOIN&lt;/STRONG&gt; is as per SAP Note &lt;STRONG&gt;1293807&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;From &lt;STRONG&gt;BASIS&lt;/STRONG&gt; end,they have updated statistics for &lt;STRONG&gt;MSEG&lt;/STRONG&gt; table along with they have updated ORACLE DB profile parameters as per SAP's latest release.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;after that also,performance is very slow and going for time out.&lt;STRONG&gt;MSEG&lt;/STRONG&gt; has 8,200,000 entries.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;pl. advice&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 09:15:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502844#M1654212</guid>
      <dc:creator>MKM</dc:creator>
      <dc:date>2012-02-21T09:15:29Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502845#M1654213</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;PRE&gt;&lt;CODE&gt;INTO CORRESPONDING FIELDS OF TABLE GIT_MKPFMSEG_P&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;please remove this and specify the fields in GIT_MKPFMSEG_P , means assign each fields .&lt;/P&gt;&lt;P&gt;Defining a structure  as per the select statement .It seems to be better not to use INTO CORRESPONDING FIELDS OF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also think of doing that from part earlier and store it somewhere and use it in the query.It will depend upon the requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: benson_10 on Feb 21, 2012 3:17 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 09:36:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502845#M1654213</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-02-21T09:36:35Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502846#M1654214</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Ben,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is a common misconception among developers that &lt;EM&gt;INTO CORRESPONDING FIELDS OF TABLE&lt;/EM&gt; causes performance issues.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;@Manoj: Can you explain your join condition in simple terms? Why are you using MKFP+MSEG combination twice? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Suhas&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS: You needn't use MANDT in your select query, it can safely be removed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Suhas Saha on Feb 21, 2012 3:29 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 09:57:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502846#M1654214</guid>
      <dc:creator>SuhaSaha</dc:creator>
      <dc:date>2012-02-21T09:57:56Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502847#M1654215</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;I think you are unnecessarily joining the same tables many times.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
   SELECT
     KT~MBLNR  "NUMBER OF MATERIAL DOCUMENT
     KT~MJAHR  "MATERIAL DOCUMENT YEAR
     KT~BUDAT  "POSTING DATE IN THE DOCUMENT
     ST~ZEILE  "ITEM IN MATERIAL DOCUMENT
     ST~BWART  "MOVEMENT TYPE (INVENTORY MANAGEMENT)
     ST~MATNR  "MATERIAL NUMBER
     ST~WERKS  "PLANT
     ST~LGORT  "STORAGE LOCATION
     ST~CHARG  "BATCH NUMBER
     ST~SHKZG  "DEBIT/CREDIT INDICATOR
     ST~MENGE  "QUANTITY
     ST~BUKRS  "COMPANY CODE
     ST~OIVBELN " DELIVERY NO
     ST~OIPOSNR
INTO CORRESPONDING FIELDS OF TABLE GIT_MKPFMSEG_P
FROM
    MKPF AS KT INNER JOIN
    MSEG AS ST ON
    KT~MBLNR = ST~MBLNR AND
    KT~MJAHR = KT~MJAHR and
    ST~ZEILE = ST~ZEILE 
    WHERE KT~BUDAT IN S_DATE
    AND  ST~MATNR EQ GWA_MARD-MATNR
    AND  ST~WERKS EQ GWA_MARD-WERKS
    AND  ST~LGORT EQ GWA_MARD-LGORT
    %_HINTS ORACLE 'INDEX(u201CMSEGu201D u201CMSEG~Mu201D)'.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try like this a simplified version for the same query. Which i think does the same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Aswath.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 10:31:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502847#M1654215</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-02-21T10:31:12Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502848#M1654216</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Benson/Suhas,&lt;/P&gt;&lt;P&gt;I have tried without using &lt;STRONG&gt;INTO CORRESPONDING FIELDS OF TABLE&lt;/STRONG&gt; also.It is not giving any significant improvement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was thinking to store the required &lt;STRONG&gt;MSEG&lt;/STRONG&gt; data in a Z table for performance improvement .But user want report in real time basis.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you ll check SAP Note 1293807,it says the reason is for &lt;STRONG&gt;Delayed Table access&lt;/STRONG&gt;. to reduce that,they are suggesting like that as per OPTIMIZER logic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT STATEMENT&lt;/P&gt;&lt;P&gt;|&lt;/P&gt;&lt;P&gt;--- FILTER&lt;/P&gt;&lt;P&gt;|&lt;/P&gt;&lt;P&gt;--- NESTED LOOPS&lt;/P&gt;&lt;P&gt;|&lt;/P&gt;&lt;P&gt;|-- NESTED LOOPS&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;| |-- NESTED LOOPS&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;1. | | |-----INDEX RANGE SCAN MKPF~BUD&lt;/P&gt;&lt;P&gt;2. | | -&lt;/P&gt;&lt;HR originaltext="-----" /&gt;&lt;P&gt;INDEX RANGE SCAN MSEG~LUZ&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;4. | --- TABLE ACCESS BY INDEX ROWID MKPF&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;3. | -&lt;/P&gt;&lt;HR originaltext="-----" /&gt;&lt;P&gt;INDEX UNIQUE SCAN MKPF~0&lt;/P&gt;&lt;P&gt;|&lt;/P&gt;&lt;P&gt;6. --- TABLE ACCESS BY INDEX ROWID MSEG&lt;/P&gt;&lt;P&gt;|&lt;/P&gt;&lt;P&gt;5. -&lt;/P&gt;&lt;HR originaltext="-----" /&gt;&lt;P&gt;INDEX UNIQUE SCAN MSEG~0&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 10:46:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502848#M1654216</guid>
      <dc:creator>MKM</dc:creator>
      <dc:date>2012-02-21T10:46:11Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502849#M1654217</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Manoj,&lt;/P&gt;&lt;P&gt;Please check performance guidelines on join on MSEG and MKPF  SAP Note 821722.&lt;/P&gt;&lt;P&gt;Also check with the order of fields (key fields)  how you declared table.( sometimes this will increase speed)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hi Suhas,&lt;/P&gt;&lt;P&gt;I can understand &lt;STRONG&gt;INTO CORRESPONDING FIELDS OF TABLE&lt;/STRONG&gt; to some 500 entires will not make performance issues, but with 8,200,000 entries here i think it will have some problem. &lt;/P&gt;&lt;P&gt;My client is having 20M 30M enties with 160 columns and he strictly dont want me using &lt;STRONG&gt;INTO CORRESPONDING FIELDS OF TABLE&lt;/STRONG&gt; . Another thing is that he dont need all column also &lt;SPAN __jive_emoticon_name="wink"&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[http://wiki.sdn.sap.com/wiki/display/profile/2007/10/04/Performance&lt;EM&gt;of&lt;/EM&gt;INTO&lt;EM&gt;CORRESPONDING&lt;/EM&gt;FIELDS&lt;EM&gt;OF&lt;/EM&gt;&lt;EM&gt;in&lt;/EM&gt;SELECTS]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: benson_10 on Feb 21, 2012 5:12 PM&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: benson_10 on Feb 21, 2012 5:20 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 11:38:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502849#M1654217</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-02-21T11:38:00Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502850#M1654218</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OP wrote:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;I have tried without using INTO CORRESPONDING FIELDS OF TABLE also.It is not giving any significant improvement.&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;I think this should put to rest your(or your client's) apprehension on using INTO CORRESPONDING FIELDS OF TABLE for tables with huge data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Of-course you shouldn't use SELECT * for all your queries, for tables with many columns(as in your case) select only the columns you want!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BR,&lt;/P&gt;&lt;P&gt;Suhas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 13:32:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502850#M1654218</guid>
      <dc:creator>SuhaSaha</dc:creator>
      <dc:date>2012-02-21T13:32:34Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502851#M1654219</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ho selective is your WHERE? IE how many rows are being returned?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 14:27:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502851#M1654219</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-02-21T14:27:04Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502852#M1654220</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OIVBELN &amp;amp; OIPOSNR aren't in the standard MSEG. Do they relate to purchase orders, outbound deliveries or what? As MSEG as such a big table I've often found it easier to read different source tables, e.G PO History when you are looking for goods receipts. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Index M on MSEG also has  BWART (movement type) in it  Do you know what the  possible values will be, in which case it could be added to the WHERE clause.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 15:46:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502852#M1654220</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-02-21T15:46:21Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502853#M1654221</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check the response from Aswath.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why are you JOINing MSEG twice? I don't think I've ever seen this before and I don't see how it could help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, you are mentioning the client in the JOIN conditions, but not the WHERE and the SELECT is not CLIENT DEPENDENT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 15:55:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502853#M1654221</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-02-21T15:55:34Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502854#M1654222</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;after using below code also,it is not giving me a significant change in time consumed for report execution.User want max with in 1-2 minute where &lt;STRONG&gt;MSEG&lt;/STRONG&gt; has 8,200,000 entries. it is taking around 30-40 minutes &amp;amp; sometimes going for Time Out Dump.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
SELECT
     KT~MBLNR  "NUMBER OF MATERIAL DOCUMENT
     KT~MJAHR  "MATERIAL DOCUMENT YEAR
     KT~BUDAT  "POSTING DATE IN THE DOCUMENT
     ST~ZEILE  "ITEM IN MATERIAL DOCUMENT
     ST~BWART  "MOVEMENT TYPE (INVENTORY MANAGEMENT)
     ST~MATNR  "MATERIAL NUMBER
     ST~WERKS  "PLANT
     ST~LGORT  "STORAGE LOCATION
     ST~CHARG  "BATCH NUMBER
     ST~SHKZG  "DEBIT/CREDIT INDICATOR
     ST~MENGE  "QUANTITY
     ST~BUKRS  "COMPANY CODE
     ST~OIVBELN " DELIVERY NO
     ST~OIPOSNR
INTO TABLE GIT_MKPFMSEG_P
FROM
    ( ( (
    MKPF AS KI INNER JOIN
    MSEG AS SI ON
    KI~MBLNR = SI~MBLNR AND
    KI~MJAHR = SI~MJAHR ) INNER JOIN
    MKPF AS KT ON
    KI~MBLNR = KT~MBLNR AND
    KI~MJAHR = KT~MJAHR ) INNER JOIN
    MSEG AS ST ON
    SI~MBLNR = ST~MBLNR AND
    SI~MJAHR = ST~MJAHR AND
    SI~ZEILE = ST~ZEILE )
    WHERE
         KI~BUDAT IN S_DATE
    AND  SI~MATNR EQ GWA_MARD-MATNR
    AND  SI~WERKS EQ GWA_MARD-WERKS
    AND  SI~LGORT EQ GWA_MARD-LGORT
    %_HINTS ORACLE 'INDEX(u201CMSEGu201D u201CMSEG~Mu201D)'.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;simplified version of the above join, I have already used previously.But not useful.&lt;/P&gt;&lt;P&gt;P.N:I have tried many different logic's to minimize the load on DATABASE server while fetching data from table. without join also,if i am doing,It is stopping in &lt;STRONG&gt;MSEG&lt;/STRONG&gt; line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't want to restrict WHERE clause BWART wise as per requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;twice &lt;STRONG&gt;MSEG&lt;/STRONG&gt; joining logic is described in the above mentioned SAP Note(1293807).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now I am thinking to go for &lt;STRONG&gt;MKPF&lt;/STRONG&gt; statitics update as per SAP Note 821722 though it for MS SQL Server. &lt;STRONG&gt;BASIS&lt;/STRONG&gt; has done for &lt;STRONG&gt;MSEG&lt;/STRONG&gt;,but not so helpful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2012 05:40:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502854#M1654222</guid>
      <dc:creator>MKM</dc:creator>
      <dc:date>2012-02-22T05:40:59Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502855#M1654223</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Note 1293807 is for Oracle databases only and the problem it addresses may have been solved already. Is your database Oracle?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2012 14:01:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502855#M1654223</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-02-22T14:01:57Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502856#M1654224</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;yes&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2012 14:12:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502856#M1654224</guid>
      <dc:creator>MKM</dc:creator>
      <dc:date>2012-02-22T14:12:04Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502857#M1654225</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Did you execute the mentioned adjustments for the indexes from that note?&lt;/P&gt;&lt;P&gt;The note states the this new MB51 ist still "pilot" stuff, so the required adjustments&lt;/P&gt;&lt;P&gt;for the indexes might not be delivered yet. Compare the indexes to what you have in your system.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The plan you posted is from the Note! What ist the plan on your system like?&lt;/P&gt;&lt;P&gt;Please use the code tags when showing us the plan.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Volker&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Feb 2012 17:52:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502857#M1654225</guid>
      <dc:creator>volker_borowski2</dc:creator>
      <dc:date>2012-02-22T17:52:33Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502858#M1654226</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Volker,&lt;/P&gt;&lt;P&gt;In our system,below following standard relevant indexes are there.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;MKPF&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Index ID: &lt;STRONG&gt;BUD&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;BUDAT	Posting Date in the Document&lt;/P&gt;&lt;P&gt;MBLNR	Number of Material Document&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;MSEG&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Index ID: &lt;STRONG&gt;M&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;MATNR	Material Number&lt;/P&gt;&lt;P&gt;WERKS	Plant&lt;/P&gt;&lt;P&gt;LGORT	Storage Location&lt;/P&gt;&lt;P&gt;BWART	Movement Type (Inventory Management)&lt;/P&gt;&lt;P&gt;SOBKZ	Special Stock Indicator&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Index ID: &lt;STRONG&gt;OIB&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;MATNR	Material Number&lt;/P&gt;&lt;P&gt;WERKS	Plant&lt;/P&gt;&lt;P&gt;LGORT	Storage Location&lt;/P&gt;&lt;P&gt;BWART	Movement Type (Inventory Management)&lt;/P&gt;&lt;P&gt;SOBKZ	Special Stock Indicator&lt;/P&gt;&lt;P&gt;OIB_TIMESTAMP	Tank dip time stamp&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using the JOIN mentioned in Page 6 of SAP Note 1293807.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am not clear on the line which plan my system is using?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Feb 2012 14:06:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502858#M1654226</guid>
      <dc:creator>MKM</dc:creator>
      <dc:date>2012-02-23T14:06:08Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502859#M1654227</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What happens when you remove the JOIN mentioned in Page 6 of SAP Note 1293807???  Does the performance get noticeably worse?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Che&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Feb 2012 14:43:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502859#M1654227</guid>
      <dc:creator>che_eky</dc:creator>
      <dc:date>2012-02-23T14:43:59Z</dc:date>
    </item>
    <item>
      <title>Re: Performance Issue with MSEG</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502860#M1654228</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Solved By Below SAP Notes by myself&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1516684:&lt;/STRONG&gt; MKPF fields added to MSEG - Performance optimization&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1550000:&lt;/STRONG&gt; MB51: Redesign of selection for performance optimization&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1558298:&lt;/STRONG&gt; MB5B: Redesign of selection to optimize performance&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1567602:&lt;/STRONG&gt; DB dependent steps to support the redesign of MB51&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1598760:&lt;/STRONG&gt; FAQ: MSEG Enhancement &amp;amp; Redesign MB51/MB5B&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks to all&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Mar 2012 08:35:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/performance-issue-with-mseg/m-p/8502860#M1654228</guid>
      <dc:creator>MKM</dc:creator>
      <dc:date>2012-03-03T08:35:54Z</dc:date>
    </item>
  </channel>
</rss>

