cousinconley
MIS
Ok, I have a record. Each record has 8 attributes that are either true or false. A record can have multiple attributes that are true. So, how do I group by the true attributes and have a record print multiple times...once under each attribute grouping?
This is what I have so far:
SELECT 'Y'
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX1}: "REDEEMED AFTER EXPIRATION DATE"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX2}: "VOUCHER NOT PROPERLY EXECUTED"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX3}: "VOUCHER IMPROPERLY IDENTIFIED"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX4}: "DEPARTMENT NOT PROPERLY IDENTIFIED"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX5}: "MISSING RECEIPT OR VOUCHER"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX6}: "VOUCHER NOT STAMPED REDEEMED"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX7}: "NO REASON GIVEN"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX8}: "CASH PRIZE ACCEPTED"
The problem is..when it groups, it prints the record under the first true attribute then goes onto the next record without evaluating the other attributes. I have also tried a FOR LOOP and got some bizarre results...non of which came close to what i was trying to accomplish.
Any suggestions?
This is what I have so far:
SELECT 'Y'
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX1}: "REDEEMED AFTER EXPIRATION DATE"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX2}: "VOUCHER NOT PROPERLY EXECUTED"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX3}: "VOUCHER IMPROPERLY IDENTIFIED"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX4}: "DEPARTMENT NOT PROPERLY IDENTIFIED"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX5}: "MISSING RECEIPT OR VOUCHER"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX6}: "VOUCHER NOT STAMPED REDEEMED"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX7}: "NO REASON GIVEN"
CASE {CNE_CMPEXP_EXCEPTION.CNE_CHECKBOX8}: "CASH PRIZE ACCEPTED"
The problem is..when it groups, it prints the record under the first true attribute then goes onto the next record without evaluating the other attributes. I have also tried a FOR LOOP and got some bizarre results...non of which came close to what i was trying to accomplish.
Any suggestions?