You can always use EXEC CICS ASSIGN SYSID() or EXEC CICS ASSIGN APPLID(). Most shops have a naming standatd with a P or T in one of the positions.
But changing behaviour depending on which region you run in is always a bad idea - how can your testers sign off on something they have never been able to run? Maybe you could change the program, and then change it back? What kind of test is that?
The best option is to minimise your JCL to a few lines that invokes a procedure (with a parameter for &ENV), and keep it on a VSAM file or database table that your program can read. The procedure gets stored on your PROCLIB, and hence can be changed at will without modifying your program. In this way you can have production/test/UAT versions of your VSAM file or table, and your program always remains the same and is not dependent on where it is running. It also means you don't have any hard coded JCL embedded in your program.
Steve
[small]"Every program can be reduced by one instruction, and every program has at least one bug. Therefore, any program can be reduced to one instruction which doesn't work." (Object:erlDesignPatterns)[/small]
My point was that it's NOT a well architected solution, and it's not testable.
Steve
[small]"Every program can be reduced by one instruction, and every program has at least one bug. Therefore, any program can be reduced to one instruction which doesn't work." (Object:erlDesignPatterns)[/small]
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.