View previous topic :: View next topic
|
Author |
Message |
mathi.vanan
New User
Joined: 11 Jan 2012 Posts: 18 Location: INDIA
|
|
|
|
I am trying to use ICETOOL in REXX as below
Code: |
"FREE FI(TOOLMSG DFSMSG INREC OUTREC CTL1CNTL LENDIST TOOLIN)"
"ALLOC FI(TOOLMSG) DA(*)"
"ALLOC FI(DFSMSG) DUMMY"
"ALLOC FI(INREC) DA('<<>>>') OLD"
"ALLOC FI(OUTREC) DA('<<<>>>') OLD"
"ALLOC FI(LENDIST) DA(*)"
"ALLOC FI(CTL1CNTL) DA('<<<>>>') SHR REUSE"
"ALLOC FI(TOOLIN) DA('<<<<>>>') SHR REUSE"
ADDRESS LINKMVS ICETOOL
|
I want to change the CTL1CNTL everytime based on certain conditions. Is there a possibility that in the above code, i can hardcode the CTL1CNTL (control card for ICETOOL) with appropriate variable names (instead of using a dataset for the control card), so that my control card changes dynamically?
I am a beginner in REXX and i am stuck with trying the correct syntax for this need.
Can someone help me out? Please let me know if my question is not clear. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
how many threads about the same idiotic problem are you going to make? |
|
Back to top |
|
|
mathi.vanan
New User
Joined: 11 Jan 2012 Posts: 18 Location: INDIA
|
|
|
|
@dbz:
Unfortunately, deleting a thread is not allowed to all members. I accept my fault in posting the same query in another forum. I was unable to delete the thread that was posted in DFSORT/ICETOOL..
Moreover, do you have an answer or any suggestion that you see as an 'idiotic' problem? |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
yeah, i have a suggestion (or two):
if you start a thread in an incorrect forum,
ask a moderator to move the thread.
look at the answer which superk provided in your other thread.
all things being equal and having little info about your problem,
you can populate any control cards that you want in a ds.
if you are generating multiple jobs, then use a different dsn for you DSN parm.
the idiotic problem is actually your inability to post a meaningful question.
take the time to explain fully what you are doing and where you need help.
do not expect us to figure out what you meant from what little you have said,
other than
you are a poor little picked-upon poster,
who is using an internet forum in an attempt to disguise his incompetence from his workplace. |
|
Back to top |
|
|
mathi.vanan
New User
Joined: 11 Jan 2012 Posts: 18 Location: INDIA
|
|
|
|
@dbz:
Thanks for your suggestion.
I need to change certain number of texts in all the members of the PDS. Say for eg..
MEMBER 1 has:
TEXT1 -------------
------- TEXT1 -----
---------------TEXT1
MEMBER 2 has:
TEX2---------------
--------------TEXT2
-------TEXT2-------
etc....
here TEXT1 shud be changed to DATA1, TEXT2 should be changed to DATA2
I have the original and final text values read from a file.
I would be executing the above mentioned rexx code in a loop to pick appropriate member names for changes.
I wanted to know if there is a possibility to run the above piece of code by hardcoding the control card statements with the rexx code, rather than creating individual control card members.
I understand that there are situations of not getting the clear requirement or question. I did mention 'Please let me know if my question is not clear'
Rather than typing a bunch of unnecessary harsh words as a response, you could have asked me to explain clearly.
I would follow a 'rule(z)' that all my posts have clear questions going forward. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
So, you're going to have to try again.
If you want to use ICETOOL and CTL1CNTL then you put the current values you want to use on the CTL1CNTL and use ICETOOL. rexx can be used for this task. You can do it more than once in a program, if you feel the need.
If you want to do the work in rexx alone, just forget ICETOOL.
ICETOOL does not know anything about getting control cards from rexx, but does know about CTL1CNTL. rexx can know about CTL1CNTL if you feel like it.
Now, what did you want to ask? |
|
Back to top |
|
|
prino
Senior Member
Joined: 07 Feb 2009 Posts: 1306 Location: Vilnius, Lithuania
|
|
|
|
Holy crap, why the fecking hell don't you use a tool that is suitable for the task, like an edit macro. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
a few thoughts:
1. the TS does not want to execute a job
jobs have a cost factor, where as foreground mode is not directly costed
2. the TS wants to sort multiple files within a session, thus the 'loop' requirement.
3. addressing the question of hardcoded control cards:
you invoke ICETOOL,
and background or foreground, regardless,
ICETOOL expects to have certain DS's allocated.
if you mean by hardcoded, inline data stream,
no, not in foreground mode.
4. you have input file with 'before and after control cards',
you will have to explain that |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Click HERE for an example of creating ICETOOL statements in REXX depending on the PARM= values selected, and also invoking the product from REXX.
Although Prinos suggestion seems far more appropriate. |
|
Back to top |
|
|
|