INDEX CREATION SUGGESTIONS RELATED TO DATABASE PERFORMANCE · The columns at the beginning of an index are the most "common". The most "common" columns are those where reports are selecting columns with no ranges - the where clause for these columns is an "equal to" expression. Rearrange columns of an index to match the selection criteria.
For example, if a select statement is written to include columns 1 and 2 with "equal to" expressions in the where clause and column 3 and 4 are selected with value ranges, then the index should be created with columns in the sequence of 1,2,3,4. · Columns towards the end of the index are either infrequently used in selects or are part of reporting selects that involve ranges of values. TABLE TYPE SUGGESTIONS RELATED TO DATABASE PERFORMANCE ·
Use VIEW tables to effectively join and "denormalize" related tables that are taking large amounts of time to select for reporting.
For example, at times where highly accessed tables normalize description text into one table and the header data into another table, it may make sense to create a view table that joins the relevant fields of the two associated with a poor performing ABAP. For POOL tables that contain large amounts of data and are highly accessed, convert the pooled table into a transparent table and add an index. POOLED tables are supposed to be collections of smaller tables that are quickly accessed from the database or are completely buffered in memory. Pooled tables containing more than a few hundred rows and are accessed many times in a report or transaction are candidates for POOL to TRANSPARENT Conversion. For example, table A053 contains tax jurisdiction condition information and are accessed more than ten times in the sales order create transaction. If the entire United States tax codes are loaded into these condition tables, the time to save a sales order increases to unacceptable levels. Converting the tax condition table to transparent and creating an index based upon the key fields, decreases processing time from minutes to seconds.
· Do not allow the use of LIKE in an SAP SQL statement accessing a large table.
· Use internal tables in ABAPs to preselect values once and store values in memory for sorting and searching purposes (this is an assumption stated at the beginning of this discussion).
· Avoid logical databases when not processing all row s of a table. In fact, a logical database is merely a group of nested SAP SQL SELECT statements. In general, when processing a small number of rows in a larger table is required, the use of internal tables and NOT using a logical database or nested selects will be much better for performance.