SOC7 on total



IBM's flagship sort product DFSORT for sorting, merging, copying, data manipulation and reporting. Includes ICETOOL and ICEGENER

SOC7 on total

Postby Dean Bashore » Thu Aug 20, 2015 10:37 pm

Hi

I've been struggling with this for two days. I will try to give all relevant information and be suscinct

I am constructing a report to sum error totals by day.

INCLUDE COND=(2,2,CH,EQ,C'50',AND,129,1,CH,NE,C'0')         
OPTION COPY                                                 
OUTFIL FNAMES=REPT2,                                       
 SECTIONS=(1,8,SKIP=P,                                     
   HEADER3=(1:JOBNAME,27:'**********************',     
   73:RPTNAM1,1/,                                           
   1:STPNAME,29:RPTTITL,73:'PAGE ',PAGE=(EDIT=(TT)),1/,     
   1:DATE,'    ',TIME=(12:),33:FREQNCY,' REPORT',2/,       
   1:'DATE  ',25:'TOKEN',45:'ORDER',55:'AMOUNT',70:'CODE', 
   77:'MESSAGE'/,                                           
   1:'----',25:'--------',45:'-----',55:'----',70:'-----', 
   77:'-------'/),                                         
   TRAILER3=(2/,10:'SUMMARY OF ERRORS       ',4/,           
   12:'NUMBER OF ERRORS IS              ',                 
   COUNT,/,                                                 
   12:'TOTAL OF ERRORS IS               ',                 
   TOTAL=(30,06,PD,M2)))                                   
   INREC IFTHEN=(WHEN=INIT,                                 
   PARSE=(%00=(ABSPOS=11,ENDBEFR=C',',FIXLEN=16),     TOKEN
*           %01=(ABSPOS=30,FIXLEN=06),                  AMOUNT 
            %02=(ABSPOS=83,ENDBEFR=C',',FIXLEN=08),     ORDER   
            %03=(ABSPOS=100,ENDBEFR=C',',FIXLEN=02),    YEAR   
            %06=(ABSPOS=102,ENDBEFR=C',',FIXLEN=04),    DATE   
            %04=(ABSPOS=217,ENDBEFR=C',',FIXLEN=05),    CODE   
            %05=(ABSPOS=292,ENDBEFR=C'"',FIXLEN=100))), MESSAGE
     IFTHEN=(WHEN=(129,4,CH,EQ,C'1026'),                       
     BUILD=(1:%06,5:%03,25:%00,45:%02,                         
     55:30,06,PD,M2,                                           
           70:%04,                                             
           77:136,66,150X)),                                   
     IFTHEN=(WHEN=NONE,                                         
     BUILD=(1:%06,5:%03,25:%00,45:%02,                         
     55:30,06,PD,M2,                                           
           70:%04,                                             
           77:%05))                                             
     OUTREC BUILD=(1,6,Y2T,M9,9,133)                           
/*                                                               


When I run the code including the line
TOTAL=(30,06,PD,M2)))


I get a SOC7

However the following statements run just fine
55:30,06,PD,M2,

Which i use twice in the builds

This is the data segment I am referencing from the first two records on the file blown up into hex for you so you can see the values
....`.
000079
00009C
3----+
     
......
000019
00019C
3----+


My entire report works except for this line and I built it from a similar report that uses the same technique to sum packed fields for the total
I have also tried every other p,m,f i could think of

Any help would be greatly appreciated

Thanks

Dean
Dean Bashore
 
Posts: 6
Joined: Thu Aug 20, 2015 10:22 pm
Has thanked: 0 time
Been thanked: 0 time

Re: SOC7 on total

Postby BillyBoyo » Fri Aug 21, 2015 3:15 am

I suspect you have some bad data. Have a look at the use of ICETOOL's VERIFY operator, and run your input through that.

The fact that you don't get an abend on the formatting means nothing. If the formatting does not require "decimal instructions", you can't possibly get a S0C7.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: SOC7 on total

Postby Dean Bashore » Fri Aug 21, 2015 3:53 am

Since this post I ran an ICETOOL verify and it verified the data. At least I think so since I have never used it before. I can post the SYSOUT when I get back to the office in the morning for you to verify.

Also I am developing with a 5 record file and have visually inspected all 5 data fields. Again I can post all 5 for your inspection as well.

I also pointed the sort that I templated this one from at the same dataset I am using and edited the p,m,f to the same range and it ran successfully. (No SOC7) this test I am certain of the results.

It also runs as BI but produces an absurd result.

Thanks for the timely response.
Dean Bashore
 
Posts: 6
Joined: Thu Aug 20, 2015 10:22 pm
Has thanked: 0 time
Been thanked: 0 time

Re: SOC7 on total

Postby Dean Bashore » Fri Aug 21, 2015 5:43 pm

Here is the TOOLMSG from the ICETOOL VERIFY I ran against my data

ICE600I 0 DFSORT ICETOOL UTILITY RUN STARTED                                   
                                                                               
ICE650I 0 VISIT http://www.ibm.com/storage/dfsort FOR ICETOOL PAPERS, EXAMPLES A
                                                                               
ICE632I 0 SOURCE FOR ICETOOL STATEMENTS:  TOOLIN                               
                                                                               
                                                                               
ICE630I 0 MODE IN EFFECT:  STOP                                                 
                                                                               
          VERIFY FROM(IN) ON(30,6,PD)                                           
ICE627I 0 DFSORT CALL 0001 FOR COPY FROM IN       TO E35 EXIT COMPLETED         
ICE628I 0 RECORD COUNT:  000000000000005                                       
ICE602I 0 OPERATION RETURN CODE:  00                                           
                                                                               
                                                                               
ICE601I 0 DFSORT ICETOOL UTILITY RUN ENDED - RETURN CODE:  00                   
Dean Bashore
 
Posts: 6
Joined: Thu Aug 20, 2015 10:22 pm
Has thanked: 0 time
Been thanked: 0 time

Re: SOC7 on total

Postby Dean Bashore » Fri Aug 21, 2015 7:23 pm

Here is 30,6 of all 5 records in hex mode in File Manager
000079
00009C
3----+
     
......
000019
00019C
3----+
     
....o.
000191
00016C
3----+
......
000070
00055C
3----+
     
....r.
000099
00009C
Dean Bashore
 
Posts: 6
Joined: Thu Aug 20, 2015 10:22 pm
Has thanked: 0 time
Been thanked: 0 time

Re: SOC7 on total

Postby BillyBoyo » Fri Aug 21, 2015 8:07 pm

You've offset the value by nine bytes. No matter where you physically code it, OUTREC (and INREC if used) would always run in the order that SORT dictates, which is always before OUTFIL. Use 39,6 and you will be OK.

 OUTREC BUILD=(1,6,Y2T,M9,9,133)
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: SOC7 on total

Postby Dean Bashore » Fri Aug 21, 2015 8:30 pm

Thanks for the response.

I'm not sure I understand what you are telling me. But if your suggestion was to use 39,6 as the p,m in the TOTAL= that doesn't work.

If you're suggestion is about modifying the OUTREC BUILD you echoed back I'm not sure what you mean.

Can you please help me understand?
Dean Bashore
 
Posts: 6
Joined: Thu Aug 20, 2015 10:22 pm
Has thanked: 0 time
Been thanked: 0 time

Re: SOC7 on total

Postby Dean Bashore » Fri Aug 21, 2015 10:47 pm

Thank you!!

Your advice led me down the right path

The solution is this

TOTAL=(55,17,UFF,M2)))
Dean Bashore
 
Posts: 6
Joined: Thu Aug 20, 2015 10:22 pm
Has thanked: 0 time
Been thanked: 0 time


Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post