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

Need help on easytrieve "GO TO JOB"


IBM Mainframe Forums -> CA Products
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
anumbhaskar

New User


Joined: 18 Feb 2008
Posts: 1
Location: Bangalore

PostPosted: Thu Jan 07, 2010 12:53 pm
Reply with quote

Hi,

I have an easytrieve step in JCL like this:

JOB INPUT (FILE1 KEY FILE1-KEY +
FILE2 KEY FILE2-KEY)

IF MATCHED FILE1 FILE2
IF FILE1-DATE EQ FILE2-DATE
GO TO JOB -----------> EXIT1
ELSE
IF FILE1-AMOUNT LT FILE2-AMOUNT
--do some calculations on file1 data--
PUTF OUTFILE1
GO TO JOB ------------->EXIT2
ELSE
--do some calculations on file2 data--
PUTF OUTFILE2
GO TO JOB -------------->EXIT3
END-IF
END-IF

File1 data is like this:
KEY Date AMT
100 10/12/2009 100.00
101 25/11/2009 150.00
101 15/12/2009 200.00
105 20/01/2010 050.00

Fille2:
KEY Date AMT
090 10/12/2009 100.00
101 25/12/2009 200.00
104 20/01/2010 050.00

"GO TO JOB" is coded at 3 places. in what order this code will read the records from 2 input files?
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jan 07, 2010 1:22 pm
Reply with quote

Please learn to post in the appropriate forum.
This is a CA product.

Topic moved.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Thu Jan 07, 2010 9:54 pm
Reply with quote

Hello and welcome to the forum,

Quote:
"GO TO JOB" is coded at 3 places. in what order this code will read the records from 2 input files?
The question has nothing to do with the statement. . . There could be more or less GO TO statements and the records will be read the same way (in the same order).

The GO TO statements mention "exit" - this could be misleading. The GO TO JOB transfers control back to the JOB statement for the next iteration.
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 -> CA Products

 


Similar Topics
Topic Forum Replies
No new posts PuTTY - "User is not a surrogate... IBM Tools 5
No new posts Newbie Stuck on "Duplicate Datas... TSO/ISPF 5
No new posts Count the number of characters in a f... CA Products 1
No new posts File matching functionality in Easytr... DFSORT/ICETOOL 14
No new posts RABBIT HOLE NEEDED - "Live"... All Other Mainframe Topics 0
Search our Forums:

Back to Top