View previous topic :: View next topic
|
Author |
Message |
rabindranathtawker
New User
Joined: 22 Jun 2007 Posts: 22 Location: Connecticut
|
|
|
|
Hello,
Can somebody help me out for the following requirement.
1) Using Rexx, I have to find the 5 recent generations of a GDG & display the contents of it in a word document.
2) Then i have to choose a job name listed in the contents of GDG (randomly from any one generation) & browse a pds (where job info is stored as members) to display the corres job info in a word document. (Assume as each generation is a report which contains list of job names)
Rabin |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Interesting project. There is nothing in your requirements that you shouldn't be able to find by searching the forums. I'll start by offering some tips:
rabindranathtawker wrote: |
Using Rexx, I have to find the 5 recent generations of a GDG ... |
Nothing in REXX will do this. The same utility you use to define and modify GDG's (IDCAMS) also can be used to query them. A quick search located a couple of useful topics:
www.ibmmainframes.com/viewtopic.php?t=18963
www.ibmmainframes.com/viewtopic.php?t=19564
The rest of the project sounds like normal logic processing and file I/O, which if you already know REXX shouldn't be much of an issue. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Another tip: Use correct terminology. GDG's are usually referred to by their generation (Gnnnn), not by their version (Vnn). |
|
Back to top |
|
|
rabindranathtawker
New User
Joined: 22 Jun 2007 Posts: 22 Location: Connecticut
|
|
|
|
Hello,
Tx frnds for ur help.. im new to rexx. i have coded my pgm - given below - till the point of browsing the 5 versions & appending all the data to a single ps. now im wondering as how to convert this to a word doc.. is there any way where ftp & rexx could be clubbed?
Code: |
$DSN = "T6201BTX.T6201.DAILY.HANG"
Q = OUTTRAP(DATA.)
ADDRESS TSO "LISTC ENT('"||$DSN||"')"
Q = OUTTRAP(OFF)
$REC = DATA.0 - 1
COUNT = 0
DO SUBSCRIPT = (DATA.0 - 1) to 1 BY -2,
UNTIL COUNT = 5
COUNT = COUNT + 1
say subscript
say count
say data.subscript
PARSE VAR DATA.subscript . . $NAME
CALL copy_file
END
EXIT
Copy_file:
Address TSO
say $name
"ALLOC F(IN) DA('"$name"') SHR"
"ALLOC F(OUT) DA('t3162btx.t3162.daily.hang.report') MOD"
'EXECIO * DISKR IN (STEM rprt. FINIS' /* copy file into stem*/
/*Queue */ /* add null line to stack */
'EXECIO * DISKW OUT (STEM rprt. FINIS' /* copy using stem*/
"FREE F(IN,OUT)"
say 'no. of lines ' data.0
RETURN |
|
|
Back to top |
|
|
rabindranathtawker
New User
Joined: 22 Jun 2007 Posts: 22 Location: Connecticut
|
|
|
|
Yes Kevin.. as u said, little search helped me to kick start this pgm.. |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
rabindranathtawker wrote: |
now im wondering as how to convert this to a word doc |
Don't know - that's a proprietary format. I'd do an internet search for text-to-word conversion utilities. I know there exists somewhere a TXT2RTF REXX utility and a TXT2PDF REXX utility.
rabindranathtawker wrote: |
is there any way where ftp & rexx could be clubbed? |
I have no idea what this statement means. FTP is a native TSO command, so it can, of course, be called by a REXX exec. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Quote: |
rabindranathtawker wrote:
is there any way where ftp & rexx could be clubbed? |
Quote: |
I have no idea what this statement means. |
I believe it means "joined" or "used together" and sometimes horizontal concatenation (rather than vertical as with DDs).
Maybe someone will share a "real" definition. . . .
d |
|
Back to top |
|
|
rabindranathtawker
New User
Joined: 22 Jun 2007 Posts: 22 Location: Connecticut
|
|
|
|
Hi Frnds,
Sry. Was out of town. so couldn't reply immd.
Kevin, what i meant was can FTP be used/invoked thru REXX by any means... I will check out on TXT2RTF utility..
Thanks all for your help.. |
|
Back to top |
|
|
|