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

JCL/OPC SCAN


IBM Mainframe Forums -> IBM Tools
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
jothibso

New User


Joined: 03 Sep 2009
Posts: 18
Location: chennai

PostPosted: Wed Mar 09, 2011 5:14 pm
Reply with quote

Hi All,

I have the following requirement in JCL

Currently i have Included the following piece in JCL

//*%OPC SCAN
//*%OPC SETFORM OCDATE=(CCYYMMDD)
//*%OPEC SETVAR TESTATE=(OCDATE - 7CD)

In this the TSDATE will have the date 1 week prior to the current date. Its working fine.

Now My new requirement is to extract 2 days prior data from the current date if it is monday and for other than Monday i need to extract 1 day prior date from the currrent date. For this I have used the following code

/*%OPC SCAN
//*%OPC SETFORM OCDATE=(CCYYMMDD)
//*If it is not a Monday */
//*%OPC BEGIN ACTION=INCLUDE,
//*%OPC SETVAR TDAY = CDAY
//*%OPC COMP=(&TDAY..NE.1)
//*%OPC SETVAR TSDATE=(OCDATE - 1CD)
//*%OPC END ACTION=INCLUDE
//*If it is Monday */
//*%OPC BEGIN ACTION=INCLUDE,
//*%OPC SETVAR TDAY = CDAY
//*%OPC COMP=(&TDAY..EQ.1)
//*%OPC SETVAR TSDATE=(OCDATE - 2CD)
//*%OPC END ACTION=INCLUDE

But the above piece of code is not working. I am getting Error as INVALID ARITHMETIC EXPRESSION. Please help.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Wed Mar 09, 2011 7:46 pm
Reply with quote

Maybe you show the TWS generated output.
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 -> IBM Tools

 


Similar Topics
Topic Forum Replies
No new posts Pipeline scan problem CICS 1
No new posts CICS TS 5.3 migr after DFHCSDUP UPGRA... CICS 6
No new posts Scan for Calls to DB2 IBM Tools 10
No new posts Using Wildcard for PDS names with PDS... CA Products 1
No new posts table scan can cause deadlock over RID? DB2 10
Search our Forums:

Back to Top