IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

INREC IFTHEN usage in COPY statement


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
rally

New User


Joined: 28 Jul 2005
Posts: 37

PostPosted: Fri Jun 22, 2007 8:15 pm
Reply with quote

Code:

   OPTION COPY                           
   INREC IFTHEN=(WHEN=(22,3,CH,NE,C'   '), 
              OVERLAY=(17:5C'0')),         
      IFTHEN=(WHEN=(108,3,CH,NE,C'   '),   
           OVERLAY=(103:5C'0'))     


I have a code as above, I found only 1st IFTHEN effect, the data changed.
but 2nd IFTHEN no change.

Any idea?
Back to top
View user's profile Send private message
krisprems

Active Member


Joined: 27 Nov 2006
Posts: 649
Location: India

PostPosted: Fri Jun 22, 2007 8:44 pm
Reply with quote

rally
Use HIT=NEXT as shown below, if both the conditions are to be checked.

Code:
OPTION COPY                           
   INREC IFTHEN=(WHEN=(22,3,CH,NE,C'   '), 
              OVERLAY=(17:5C'0'),HIT=NEXT),           
      IFTHEN=(WHEN=(108,3,CH,NE,C'   '),   
           OVERLAY=(103:5C'0'))     
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Fri Jun 22, 2007 9:19 pm
Reply with quote

BTW, you don't need three blanks for the constant - you can use C' ' (one blank). DFSORT will pad the constant with blanks to the length of the field.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts VB to VB copy - Full length reached SYNCSORT 8
No new posts Need COBOL COPY Help in MVS Environment COBOL Programming 4
No new posts Issue after ISPF copy to Linklist Lib... TSO/ISPF 1
No new posts DB2 Table - Image copy unload IBM Tools 2
No new posts How to copy the -1 version of a membe... TSO/ISPF 4
Search our Forums:

Back to Top