Append Text on HEX'00' with DFSORT



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

Append Text on HEX'00' with DFSORT

Postby ThomasThoss » Mon Mar 05, 2018 9:40 pm

Hi there,

i have the following Situation and need some help please.

Input File RECL 62.

                           >------TEXT-FIELD--------------<
0001000101BEUSERID000000EF1DTEXT10000000000000000000000000EFDE
0001000101BEUSERID000000EF1DSOMETEXT1000000000000000000000EFDE
 

Pos 1-28 Some Binary Decimal and Chars
Pos 29-59 TEXTFIELD CHAR 30 Bytes filled with HEX'00'
Pos 60-61 Binary Decimal

Now, i have a DFSORT that will make a Overlay on the Char Field at Position 29. So far, so good.
....
OVERLAY=(29:C'. TEST OK')
...
 


That will Result in

                           >------TEXT-FIELD--------------<
0001000101BEUSERID000000EF1DTEST OK00000000000000000000000EFDE
0001000101BEUSERID000000EF1DTEST OKT1000000000000000000000EFDE
 

To remove the Overlayed Text TEST OKT1 i am able to Change the Overlay to:
....
OVERLAY=(29:C'. TEST OK',X23'00')
...
 

With the Result

                           >------TEXT-FIELD--------------<
0001000101BEUSERID000000EF1DTEST OK00000000000000000000000EFDE
0001000101BEUSERID000000EF1DTEST OK00000000000000000000000EFDE
 


But what i need is to append my Text at the First Position of a Hex '00' in the Textfield between Position 29-59 so the Result should be:

                           >------TEXT-FIELD--------------<
0001000101BEUSERID000000EF1DTEXT1TEST OK000000000000000000EFDE
0001000101BEUSERID000000EF1DSOMETEXT1TEST OK00000000000000EFDE
 

How am i able to give the Overlay the instructions to append a Text on the Fist Position of a Hex'00' in a Textfield?

Best Regards Thomas
ThomasThoss
 
Posts: 2
Joined: Mon Mar 05, 2018 8:50 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Append Text on HEX'00' with DFSORT

 

Re: Append Text on HEX'00' with DFSORT

Postby expat » Tue Mar 06, 2018 12:35 pm

Try here http://ibmmainframes.com/about45948.html

Amazing what google can find you ......
expat
 
Posts: 402
Joined: Sat Jun 09, 2007 3:21 pm
Has thanked: 0 time
Been thanked: 4 times

Re: Append Text on HEX'00' with DFSORT

Postby ThomasThoss » Tue Mar 06, 2018 12:56 pm

expat wrote:Try here http://ibmmainframes.com/about45948.html
Amazing what google can find you ......

Thx, i allready asked google.
But this is not what i am looking for.
I allready have all my include conditions, joinkey and reformat Statements. That is working absolute perfect.

JOINKEYS FILE=F1,FIELDS=(1,2,A...)
JOINKEYS FILE=F2,FIELDS=(1,2,A...)
  REFORMAT FIELDS=(F1:1,...F2:...)
  OPTION COPY
  INCLUDE COND=(1,2...)
  OUTREC IFTHEN=(WHEN=(3,2,ZD,EQ,2),
      OVERLAY=(1:X'0003',3:X'0000',5:X'0000'...
               29:C'. Append Text '...)
 

So here is my question again.

                          >------TEXT-FIELD--------------<
0001000101BEUSERID000000EF1DTEXT1TEST OK000000000000000000EFDE
0001000101BEUSERID000000EF1DSOMETEXT1TEST OK00000000000000EFDE

How am i able to give the Overlay the instructions to append a Text on the Fist Position of a Hex'00' in a Textfield?
ThomasThoss
 
Posts: 2
Joined: Mon Mar 05, 2018 8:50 pm
Has thanked: 0 time
Been thanked: 0 time


Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post