v
A field name must be preceded by a 1- to 3-character file identifier if that field name is used in more
than one file selected for the query.
v
You can specify up to 100 join tests.
v
For a matched-record join, if one or both fields in a join test are null, the records are not joined.
v
The data in both fields of a join test must be the same type (for example, both character), except that
date, time, or timestamp fields can be compared to SBCS character, DBCS-either, or DBCS-open fields
that contain a correct representation of a date, time, or timestamp. Dates in character fields must be
either in the date format of the query or in an SAA
®
format— the SAA format is recommended. Date,
time, and timestamp fields are identified by an L, T, or Z, respectively, in the
Dec
column of the field list.
Note:
When comparing a date, time, or timestamp field with an SBCS, DBCS-either, or DBCS-open
character field, use a character field for which each value can be recognized as an SAA
formatted date, time, or timestamp. If the character field contains a correct representation of a
date, time, or timestamp but in other than an SAA format, you may get unexpected results. When
you run a query that uses a non-SAA format for date, time, or timestamp values in character
fields, and query has no setting for a non-SAA literal date value, use the CHGJOB command to
make sure your job date format and separator match the format and separator in the character
field values.
If some of the fields contain bracketed double-byte characters, you can use these DBCS fields for both
fields, or you can use an SBCS character field for one field and a DBCS-either or DBCS-open field for
the other field. Bracketed-DBCS fields are identified by a J, O, or E in the
Dec
column in the list of
fields. Press F11 to see the
Dec
column if it is not currently shown.
A DBCS-graphic field can be compared only to another DBCS-graphic field. DBCS-graphic fields are
identified by a G in the
Dec
column. Collating sequence is not applied to DBCS-graphic fields used in
join comparisons.
Valid comparisons for join tests are:
– Numeric field with numeric field
– SBCS character field with:
- SBCS character
- Date
- Time
- Timestamp
- DBCS-either
- DBCS-open
– Date field with:
- Date
- SBCS character
- DBCS-either
- DBCS-open
– Time field with:
- Time
- SBCS character
- DBCS-either
- DBCS-open
– Timestamp field with:
- Timestamp
- SBCS character
Chapter 4. Specifying and selecting files for a Query for iSeries query
45
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 ...