Mike Wood <[EMAIL PROTECTED]> wrote on 10/26/2005 11:39:55 AM:
> Frank, The INCLUDE statement used
> INCLUDE COND=((5,1,CH,EQ,C'X'),
> AND,
> ((164,8,CH,EQ,C'SHELF'),
> AND,
> (1326,5,CH,LT,C' 2')),
> AND,
> (156,8,CH,EQ,C'VLT1'),
> OR,
> (156,8,CH,EQ,C'DR2H'),
> OR,
> (156,8,CH,EQ,C'DR8H'),
> OR,
> (156,8,CH,EQ,C'DR8A'),
> OR,
> (156,8,CH,EQ,C'DR8B'),
> OR,
> (156,8,CH,EQ,C'DR8C'))
> should have avoided including any record which did NOT have 'X' in column
> 5. Maybe I read the AND and OR logic wrong, but seems that the first 3
> fields must all be true, and the final field can be any one of the 6
> values. Will a short record be included regardless of the INCLUDE logic?
Mike,
Not according to my tests. I tried it with a record that had a 'V' in 5
and 'DR8H' in 156 and the record was included. It would require another
set of parentheses after the last AND to work the way you're saying:
...
AND,
((156,8,CH,EQ,C'VLT1'),
OR,
(156,8,CH,EQ,C'DR2H'),
OR,
(156,8,CH,EQ,C'DR8H'),
OR,
(156,8,CH,EQ,C'DR8A'),
OR,
(156,8,CH,EQ,C'DR8B'),
OR,
(156,8,CH,EQ,C'DR8C')))
With that extra set of parentheses, my test shows the 'V'/'DR8H' record is
not included.
With VLSCMP in effect, the short records are treated as if they are padded
with binary zeros, so they may or may not be included depending on the
specific condition in relation to the binary zeros.
Frank Yaeger - DFSORT Team (IBM)
Specialties: ICETOOL, IFTHEN, OVERLAY, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort/
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html