ibm-information-center/dist/eclipse/plugins/i5OS.ic.rzajq_5.4.0.1/howeviworks.htm

72 lines
4.4 KiB
HTML
Raw Normal View History

2024-04-02 14:02:31 +00:00
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="security" content="public" />
<meta name="Robots" content="index,follow" />
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
<meta name="DC.Type" content="concept" />
<meta name="DC.Title" content="How the EVI works" />
<meta name="abstract" content="EVIs work in different ways for costing and implementation." />
<meta name="description" content="EVIs work in different ways for costing and implementation." />
<meta name="DC.Relation" scheme="URI" content="whatareevi.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="howeviworks" />
<meta name="DC.Language" content="en-us" />
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
<link rel="stylesheet" type="text/css" href="./ic.css" />
<title>How the EVI works</title>
</head>
<body id="howeviworks"><a name="howeviworks"><!-- --></a>
<img src="./delta.gif" alt="Start of change" /><!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">How the EVI works</h1>
<div><p>EVIs work in different ways for costing and implementation.</p>
<p>For costing, the optimizer uses the symbol table to collect metadata information
about the query.</p>
<p>For implementation, the optimizer may use the EVI in one of the following
ways:</p>
<ul><li><strong>Selection (WHERE clause)</strong><p>If the optimizer decides to use an EVI
to process the query, the database engine uses the vector to build the dynamic
bitmap (or a list of selected row ids) that contains one bit for each row
in the table, the bit being turned on for each selected row. Like a bitmap
index, these intermediate dynamic bitmaps (or lists) can be AND'ed and OR'ed
together to satisfy an ad hoc query.</p>
<p>For example, if a user wants to
see sales data for a certain region during a certain time period, you can
define an EVI over the region column and the Quarter column of the database.
When the query runs, the database engine builds dynamic bitmaps using the
two EVIs and then ANDs the bitmaps together to produce a bitmap that contains
only the relevant rows for both selection criteria. This AND'ing capability
drastically reduces the number of rows that the server must read and test.
The dynamic bitmap(s) exists only as long as the query is executing. Once
the query is completed, the dynamic bitmap(s) are eliminated.</p>
</li>
<li><strong>Grouping or Distinct</strong><p>The symbol table within the EVI contains
the distinct values for the specified columns in the key definition, along
with a count of the number of records in the base table that have each distinct
value. The symbol table in effect contains the grouping results of the columns
in that key. Therefore, queries involving grouping or distinct on the columns
in that key are potential candidates for a technique that uses the symbol
table directly to determine the query result. Note that the symbol table contains
only the key values and their associated counts. Therefore, queries involving
column function COUNT are eligible for this technique, but queries involving
column functions MIN or MAX on other columns are not eligible (since the min
and max values are not stored in the symbol table).</p>
</li>
</ul>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="whatareevi.htm" title="An encoded vector index (EVI) is an index object that is used by the query optimizer and database engine to provide fast data access in decision support and query reporting environments.">Encoded vector indexes</a></div>
</div>
</div>
<img src="./deltaend.gif" alt="End of change" /></body>
</html>