ibm-information-center/dist/eclipse/plugins/i5OS.ic.dbp_5.4.0.1/rbafooqfpcgrp.htm

66 lines
4.0 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="Grouping, joining, and selection: Open Query File (OPNQRYF) command performance" />
<meta name="abstract" content="When using an existing index, the optimizer ensures that the attributes of the selection, join, and grouping fields match the attributes of the keys in the existing index." />
<meta name="description" content="When using an existing index, the optimizer ensures that the attributes of the selection, join, and grouping fields match the attributes of the keys in the existing index." />
<meta name="DC.subject" content="performance, grouping, joining, and selection, grouping, joining, selection" />
<meta name="keywords" content="performance, grouping, joining, and selection, grouping, joining, selection" />
<meta name="DC.Relation" scheme="URI" content="rbafooqfsst.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="rbafooqfpcgrp" />
<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>Grouping, joining, and selection: Open Query File (OPNQRYF) command
performance</title>
</head>
<body id="rbafooqfpcgrp"><a name="rbafooqfpcgrp"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Grouping, joining, and selection: Open Query File (OPNQRYF) command
performance</h1>
<div><p>When using an existing index, the optimizer ensures that the attributes
of the selection, join, and grouping fields match the attributes of the keys
in the existing index.</p>
<p>Also, the sort sequence table associated with the query must match the
sequence table (a sort sequence table or an alternate collating sequence table)
associated with the key field of the existing index. If the sequence tables
do not match, the existing index cannot be used.</p>
<div class="p">However, if the sort sequence table associated with the query is a unique-weight
sequence table (including *HEX), some additional optimization is possible.
The optimizer acts as though no sort sequence table is specified for any grouping
fields or any selection or join predicates that use the following operators
or functions: <ul><li>*EQ</li>
<li>*NE</li>
<li>*CT</li>
<li>%WLDCRD</li>
<li>%VALUES</li>
</ul>
</div>
<div class="p">The advantage is that the optimizer is free to use any existing access
path where the keys match the field and the access path either: <ul><li>Does not contain a sequence table.</li>
<li>Contains a unique-weight sequence table (the table does not have to match
the unique-weight sort sequence table associated with the query).</li>
</ul>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="rbafooqfsst.htm" title="Here are tips and techniques for optimizing the performance of sort sequence tables.">Open Query File (OPNQRYF) command: Performance considerations for sort sequence tables</a></div>
</div>
</div>
</body>
</html>