<?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: index creation in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081069#M431722</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Arun,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An Index is created on a table to enable faster search on that table. There are two types of index - Primary and Secondary.&lt;/P&gt;&lt;P&gt;Primary index is automatically created when you create a table. It is created for all primary keys of that table.&lt;/P&gt;&lt;P&gt;Secondary index are created if you want to search a table on fields other than the primary fields. To create a secondary Index goto SE11 -&amp;gt; give tablename -&amp;gt; Indexes -&amp;gt; Specify fields you want to create an index on.&lt;/P&gt;&lt;P&gt;In your program, in the select query on the table, specify the fields on which you have created an Index in the Where clause. Remember to keep the order of fields same as they appear in the Index.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Before creating a secondary index for performance improvement you must try out other ways. Creating a secondary index should be only a last option as it causes an overhead whenever the table is queried (for fields other than those in the Index).&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;Regards,&lt;/P&gt;&lt;P&gt;Saurabh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 12 Apr 2007 12:06:57 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-04-12T12:06:57Z</dc:date>
    <item>
      <title>index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081060#M431713</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can any body tel  wats the use of using index in a table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;how to create index  in a table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;how to use in a pgm&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 11:53:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081060#M431713</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T11:53:44Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081061#M431714</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Indexes are used to fetch the data from the table fastly.&lt;/P&gt;&lt;P&gt;We will create the indexes on few fields which will serve as a fast search criteria to fetch the data&lt;/P&gt;&lt;P&gt;go to SE 11&lt;/P&gt;&lt;P&gt;enter table name &lt;/P&gt;&lt;P&gt;change&lt;/P&gt;&lt;P&gt;from menu GOTO -&amp;gt; INDEXES&lt;/P&gt;&lt;P&gt;Create Index - enter name &lt;/P&gt;&lt;P&gt;enter fields&lt;/P&gt;&lt;P&gt;save &lt;/P&gt;&lt;P&gt;activate&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;while fetching data from the table in the where condition use these fields on which the index has been created &lt;/P&gt;&lt;P&gt;reward if useful&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;ANJI&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Anji Reddy Vangala&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 11:56:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081061#M431714</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T11:56:25Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081062#M431715</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;Index is used for the faster fetching of the data.&lt;/P&gt;&lt;P&gt;Primary index is already in the table which combines&lt;/P&gt;&lt;P&gt;to give u an unique key.&lt;/P&gt;&lt;P&gt;Secondary index is the index which u create by clicking &lt;/P&gt;&lt;P&gt;on the Indexes button on application toolbar in se11 txn.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;Regds&lt;/P&gt;&lt;P&gt;Seema&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 11:58:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081062#M431715</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T11:58:08Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081063#M431716</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;See if you are fetching data from some table let us take RESB reservations which has  as primary key but you have only matnr and werks with you to hit that RESB table,..&lt;/P&gt;&lt;P&gt;it less the performance but Matnr and werks are used as secondary indexes in RESB so you can hit the table with these two fields,,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Indexes help to speed up selection from the database. They consist of a sorted copy of certain database table fields. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Creating an index &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can create an index in Transaction SE11 by choosing Change &amp;amp;#8594; Indexes... &amp;amp;#8594; Create. To make the index unique, select UNIQUE. To specify the fields that will comprise the index, choose "Choose fields". You then need to save and activate the index. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When to create an index &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is worth creating an index when: &lt;/P&gt;&lt;P&gt;You want to select table entries based on fields that are not contained in an index, and the response times are very slow. &lt;/P&gt;&lt;P&gt;The EXPLAIN function in the SQL trace shows which index the system is using. You can generate a list of the database queries involved in an action by entering Transaction ST05 and choosing Trace on &amp;amp;#8594; Execute action &amp;amp;#8594; Trace off &amp;amp;#8594; List trace. If you execute the EXPLAIN SQL function on a EXEC, REEXEC, OPEN, REOPEN or PREPARE statement, the system returns a list containing the index used in the database query. &lt;/P&gt;&lt;P&gt;The field or fields of the new secondary index are so selective that each index entry corresponds to at most 5% of the total number of table entries. Otherwise, it is not worth creating the index. &lt;/P&gt;&lt;P&gt;The database table is accessed mainly for reading entries. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can ue in the program straight away as you do for primary keys..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select ** from RESB where matnr = It_mara-marnt...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope you understood,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if usefull&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;nazeer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 11:59:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081063#M431716</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T11:59:29Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081064#M431717</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Arun,&lt;/P&gt;&lt;P&gt; There are 2 type of indexes available.&lt;/P&gt;&lt;P&gt;Primary index: with out this we can't create the table.&lt;/P&gt;&lt;P&gt;Secondary index: this is for using in the where condition in the select statement. &lt;/P&gt;&lt;P&gt;For this INDEX button is available on the application tool bar, if u press that then all indexess list wil be avaialble.&lt;/P&gt;&lt;P&gt;Hope this helps you, reply for queries, Shall post you the updates.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.  &lt;/P&gt;&lt;P&gt;Kumar. .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 12:00:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081064#M431717</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T12:00:02Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081065#M431718</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;1.In SE11 Transaction display your table.&lt;/P&gt;&lt;P&gt;2.press button index... in tool bar, it will ask you &lt;/P&gt;&lt;P&gt;to create a new one.&lt;/P&gt;&lt;P&gt;3.give the index name&lt;/P&gt;&lt;P&gt;4. give short text description&lt;/P&gt;&lt;P&gt;5. in bottom table give the field name on which&lt;/P&gt;&lt;P&gt;you want index.&lt;/P&gt;&lt;P&gt;6. save and activate.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check this.&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.oreilly.com/catalog/sapadm/chapter/ch01.html" target="test_blank"&gt;http://www.oreilly.com/catalog/sapadm/chapter/ch01.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To create Secondary Index --&amp;gt; &lt;A href="http://help.sap.com/saphelp_nw2004s/helpdata/en/cf/21eb47446011d189700000e8322d00/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw2004s/helpdata/en/cf/21eb47446011d189700000e8322d00/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt; Sudheer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 12:00:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081065#M431718</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T12:00:12Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081066#M431719</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Creating Secondary Indexes &lt;/P&gt;&lt;P&gt;Procedure&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       1.      In the maintenance screen of the table, choose Indexes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If indexes already exist on the table, a list of these indexes is displayed. Choose .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       2.      In the next dialog box, enter the index ID and choose &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The maintenance screen for indexes appears.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       3.      Enter an explanatory text in the field Short text.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can then use the short text to find the index at a later time &amp;#150; for example through the Information System.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       4.      Select the table fields to be inserted in the index using the input help for the Field name column. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The order of the fields in the index is very important. See What to Keep in Mind for Secondary Indexes&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       5.      If the values in the index fields already uniquely identify each record of the table, select Unique index.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A unique index is always created in the database at activation because it also has a functional meaning (prevents double entries of the index fields).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       6.      If it is not a unique index, leave Non-unique index selected.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In this case you can use the radio buttons to define whether the index should be created for all database systems, for selected database systems or not at all in the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       7.      Select for selected database systems if the index should only be created for selected database systems.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Click on the arrow behind the radio buttons. A dialog box appears in which you can define up to 4 database systems with the input help. Select Selection list if the index should only be created on the given database systems. Select Exclusion list if the index should not be created on the given database systems. Choose .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       8.      Choose .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Result&lt;/P&gt;&lt;P&gt;The secondary index is automatically created on the database during activation if the corresponding table has already been created there and index creation was not excluded for the database system.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can find information about the activation flow in the activation log, which you can call with Utilities ® Activation log. If errors occurred when activating the index, the activation log is automatically displayed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check... &lt;A href="http://help.sap.com/saphelp_nw2004s/helpdata/en/cf/21eb47446011d189700000e8322d00/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw2004s/helpdata/en/cf/21eb47446011d189700000e8322d00/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 12:04:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081066#M431719</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T12:04:17Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081067#M431720</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Arun,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. The standard table is the most appropriate type if you are going to address the individual table entries using the index.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2.&amp;lt;b&amp;gt; Index access is the quickest possible access. &amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. You should fill a standard table by appending lines (ABAP APPENDstatement), and read, modify and delete entries by specifying the index (INDEX option with the relevant ABAP command). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. The access time for a standard table increases in a linear relationship with the number of table entries.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;5.  If you need key access, standard tables are particularly useful if you can fill and process the table in separate steps. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;6. For example, you could fill the table by appending entries, and then sort it. If you use the binary search option (BINARY) with key access, the response time is logarithmically proportional to the number of table entries.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;7. Example code:&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;U can also read an internal table using &amp;lt;b&amp;gt;INDEX.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;read table it_tab into wa_tab with index &amp;lt;n&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;where &amp;lt;n&amp;gt; is the integer which specifies the record number in the internal table it_tab.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Thasneem&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if helpful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 12:04:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081067#M431720</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T12:04:56Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081068#M431721</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;  How many secondary indexes can we created?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Ravi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 12:05:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081068#M431721</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T12:05:50Z</dc:date>
    </item>
    <item>
      <title>Re: index creation</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081069#M431722</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Arun,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An Index is created on a table to enable faster search on that table. There are two types of index - Primary and Secondary.&lt;/P&gt;&lt;P&gt;Primary index is automatically created when you create a table. It is created for all primary keys of that table.&lt;/P&gt;&lt;P&gt;Secondary index are created if you want to search a table on fields other than the primary fields. To create a secondary Index goto SE11 -&amp;gt; give tablename -&amp;gt; Indexes -&amp;gt; Specify fields you want to create an index on.&lt;/P&gt;&lt;P&gt;In your program, in the select query on the table, specify the fields on which you have created an Index in the Where clause. Remember to keep the order of fields same as they appear in the Index.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Before creating a secondary index for performance improvement you must try out other ways. Creating a secondary index should be only a last option as it causes an overhead whenever the table is queried (for fields other than those in the Index).&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;Regards,&lt;/P&gt;&lt;P&gt;Saurabh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Apr 2007 12:06:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/index-creation/m-p/2081069#M431722</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-12T12:06:57Z</dc:date>
    </item>
  </channel>
</rss>

