v
0 through 9 (single-precision) or 0 through 17 (double-precision) for floating-point fields
For date, time, timestamp and DBCS fields, you cannot change the length to anything but 0, which
excludes the field from the report.
For numeric fields, if you increase or decrease the value in
Dec
, you should increase or decrease the
value in
Len
the same amount. If you change the value in
Len
or
Dec
but decide you want to use the
original field definition value, blank out the number you typed. If there is a value in the
Len
or
Dec
column
for the same field, you must blank it out also. If you blank out the values, the original length and decimal
values are used in the report.
The length and the number of
decimal positions
first shown for each numeric field from a file is the same
as defined in the field definition. The length and the number of decimal positions first shown for each
result
field
is the number that Query calculates for you, or is the number that you typed in the
Len
and
Dec
columns on the Define Result Fields display.
For numeric fields, the number in the
Dec
column indicates the number of positions to the right of the
decimal point.
For non-numeric fields, the type of field is shown in the
Dec
column and cannot be changed:
v
An all-blank
Dec
column identifies a fixed-length SBCS character field
v
V means variable-length
v
J means DBCS-only
v
O means DBCS-open (mixed)
v
E means DBCS-either
v
G means DBCS-graphic
v
L means Date
v
T means Time
v
Z means Timestamp
Changing the
Dec
value affects only how the field appears in your query output. The actual value is not
changed in the field definition. If you want to change the actual number of decimal positions for a result
field, you should make the changes on the Define Result Fields display rather than at this time.
For numeric fields, you can type your own value (0 through 31) for decimal positions, but you must not
enter a value for
Dec
that is greater than the length of the field.
Omitting fields from a Query for iSeries report
You can create different versions of the same basic query output by selecting all of the possible fields you
might want to include when you select and sequence fields, and then omit certain fields during the
formatting processing by entering a length of zero on the Specify Report Column Formatting display. Each
of these versions can be saved and run as separate queries.
You may also want to use a field for sorting or for a report break, but not want it to appear in the query
report. If you change the field length (
Len
prompt) to zero on the Specify Report Column Formatting
display, the field is not printed, displayed, or used for summary output sent to a database file. The field is
still used for sorting, record selection, report breaks, and break text insert (see the appropriate Chapters
for details).
If you type a zero in the
Len
column, and there is a number in the
Dec
column for the same field, you
must also enter a zero for the
Dec
column.
Chapter 10. Specifying report column formatting in Query for iSeries
121
Summary of Contents for ISERIES SC41-5210-04
Page 1: ...iSeries Query for iSeries Use Version 5 SC41 5210 04 ERserver ...
Page 2: ......
Page 3: ...iSeries Query for iSeries Use Version 5 SC41 5210 04 ERserver ...
Page 12: ...x Query for iSeries Use V5R2 ...
Page 14: ...2 Query for iSeries Use V5R2 ...
Page 32: ...20 Query for iSeries Use V5R2 ...
Page 38: ...26 Query for iSeries Use V5R2 ...
Page 44: ...32 Query for iSeries Use V5R2 ...
Page 116: ...104 Query for iSeries Use V5R2 ...
Page 122: ...110 Query for iSeries Use V5R2 ...
Page 146: ...134 Query for iSeries Use V5R2 ...
Page 150: ...138 Query for iSeries Use V5R2 ...
Page 174: ...162 Query for iSeries Use V5R2 ...
Page 178: ...166 Query for iSeries Use V5R2 ...
Page 196: ...184 Query for iSeries Use V5R2 ...
Page 198: ...186 Query for iSeries Use V5R2 ...
Page 204: ...192 Query for iSeries Use V5R2 ...
Page 205: ...Part 4 Appendixes Copyright IBM Corp 2000 2002 193 ...
Page 206: ...194 Query for iSeries Use V5R2 ...
Page 210: ...198 Query for iSeries Use V5R2 ...
Page 242: ...230 Query for iSeries Use V5R2 ...
Page 256: ...244 Query for iSeries Use V5R2 ...
Page 270: ...258 Query for iSeries Use V5R2 ...
Page 272: ...260 Query for iSeries Use V5R2 ...
Page 292: ...280 Query for iSeries Use V5R2 ...
Page 293: ......
Page 294: ... Printed in U S A SC41 5210 04 ...