Select Sort Fields
Type sort priority (0-999) and A (Ascending) or D (Descending) for
the names of up to 32 fields, press Enter.
Sort
Prty A/D Field
___ _ ACCTNUMBER
30 _ INIT
20 _ LASTNAME
___ _ STREETADDR
___ _ STATE
___ _ CITY
___ _ ZIPCODE
10 D CRLIMIT
Bottom
F3=Exit
F5=Report
F11=Display text
F12=Cancel
F13=Layout
F18=Files
F20=Renumber
F24=More keys
When you press the Enter key after typing your sort priority numbers, Query rearranges the fields on the
display in the following order:
v
If fields were selected on the Select and Sequence Fields display, they are listed in the following order:
1. All sort fields (if any) previously selected on this display, in the order specified.
2. Fields selected for the query, but not selected as a sort field. These fields are listed in the order they
were specified on the Select and Sequence Fields display.
v
If
no
fields were selected on the Select and Sequence Fields display, the fields on this display are
shown in the following order:
1. All sort fields (if any) previously selected on this display, in the order specified.
2. Any result fields that have been defined for this query.
3. All other fields, in the order they exist in the record format definitions for the selected files. Fields
from the first file are listed first, followed by those in the second file, and so on.
Query then displays a message
Press Enter to confirm.
so that you have a second chance to review
your sort fields and change them if you want.
To remove a sort field from your selections, blank out the number in front of that field name. It is not
necessary to renumber the other fields. To change the priorities of the sort fields, just change the numbers.
If you make any changes, press the Enter key again. The list of field names is rearranged and is shown
with the sort fields first, in the sort priority you specified followed by the remaining fields that were selected
for output. If you want to renumber the fields in added amounts of 10 (10, 20, 30, and so on), press F20.
When you are satisfied that your sort field selections are correct, press the Enter key a final time to end
sort field selection.
The following is an example of how to specify sort priorities.
Assume that you are the credit manager for the United States division of an international mail-order
company, and you want a report of customer names and addresses organized as follows:
v
Customers with the highest credit limit should appear first, then the next highest, and so on.
v
If two or more customers from the same state have the same credit limit, these customers should be
grouped by state.
106
Query for iSeries Use V5R2
Содержание @server iSeries
Страница 1: ...iSeries Query for iSeries Use Version 5 SC41 5210 04 ERserver ...
Страница 2: ......
Страница 3: ...iSeries Query for iSeries Use Version 5 SC41 5210 04 ERserver ...
Страница 12: ...x Query for iSeries Use V5R2 ...
Страница 14: ...2 Query for iSeries Use V5R2 ...
Страница 18: ...Figure 3 Major Tasks on the Query Menu and the Work with Queries Display 6 Query for iSeries Use V5R2 ...
Страница 32: ...20 Query for iSeries Use V5R2 ...
Страница 38: ...26 Query for iSeries Use V5R2 ...
Страница 44: ...32 Query for iSeries Use V5R2 ...
Страница 116: ...104 Query for iSeries Use V5R2 ...
Страница 122: ...110 Query for iSeries Use V5R2 ...
Страница 146: ...134 Query for iSeries Use V5R2 ...
Страница 150: ...138 Query for iSeries Use V5R2 ...
Страница 174: ...162 Query for iSeries Use V5R2 ...
Страница 178: ...166 Query for iSeries Use V5R2 ...
Страница 196: ...184 Query for iSeries Use V5R2 ...
Страница 198: ...186 Query for iSeries Use V5R2 ...
Страница 204: ...192 Query for iSeries Use V5R2 ...
Страница 205: ...Part 4 Appendixes Copyright IBM Corp 2000 2002 193 ...
Страница 206: ...194 Query for iSeries Use V5R2 ...
Страница 210: ...198 Query for iSeries Use V5R2 ...
Страница 242: ...230 Query for iSeries Use V5R2 ...
Страница 256: ...244 Query for iSeries Use V5R2 ...
Страница 270: ...258 Query for iSeries Use V5R2 ...
Страница 272: ...260 Query for iSeries Use V5R2 ...
Страница 292: ...280 Query for iSeries Use V5R2 ...
Страница 293: ......
Страница 294: ... Printed in U S A SC41 5210 04 ...