View previous topic :: View next topic
|
Author |
Message |
abhijit.nayak01
Active User
Joined: 22 Mar 2009 Posts: 161 Location: South Africa
|
|
|
|
Hi,
Please see the below connect direct cards which I am using. But I got
a requirement to automate it. The requirement is to pull the file
which is created before 2 days. i.e if today is 2013-01-07 then i need to
pull 2013-01-05 file also the date format is CCYY-MM-DD i.e. hypen is used
in between the dates. SUBDATE1 doesn't allows hypen.
Code: |
SIGNON USERID=(XXXX,XXXX) -
CASE=YES -
ESF=YES
SUBMIT PROC=COPY2YYY SNODE=DEVELOP -
MAXDELAY=QUEUED -
NEWNAME=CPY2DEV1 -
PLEXCLASS=(RC12,RC12) -
&DIRA=RELC &DIRB=usr &DIRC=aci -
&DIRD=abcde &DIRE=v1234 &DIRF=unix12 -
&DIRG=logs -
&IFILE=unix.2013-01-03.log -
&TODSN=TEST.UNIXLOGS.BKUP -
&FRDISP=SHR -
&TODISP=SHR -
&COMP='COMPRESS EXT'
SIGNOFF
COPY2YYY PROCESS
SYMBOL &FRDSN=\'\ || / || -
&DIRA || / || &DIRB || / || &DIRC || / || -
&DIRD || / || &DIRE || / || &DIRF || / || -
&DIRG || / || &IFILE || -
\'\
STEP01 COPY FROM (DSN=&FRDSN DISP=&FRDISP -
SNODE) &COMP -
TO (DSN=&TODSN DISP=&TODISP -
PNODE) |
Thanks,
Abhijit |
|
Back to top |
|
|
abhijit.nayak01
Active User
Joined: 22 Mar 2009 Posts: 161 Location: South Africa
|
|
|
|
Hi,
By using the BPXBATCH in previos step I canfetch the file name. But now the question comes how I will put the file name from the output of BPXBATCH to the CD.
Thanks,
Abhijit. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Where is the output from BPXBATCH written now?
Where do you want it on the CD? |
|
Back to top |
|
|
abhijit.nayak01
Active User
Joined: 22 Mar 2009 Posts: 161 Location: South Africa
|
|
|
|
Hi,
I am able to do the CD successfully now. Wrote a shell command script which gave me output .
&IFILE=unix file name with date as per requirement
SIGNOFF
Used the above o/p in STDOUT which I made temp DSN.
Used the same &&temp DSN in next step i.e. CD step.
Fortunately it worked.
Did more analysis on UNIX side as I realised CD has limitations.
But after the above successful steps I realised I could have solved this issue by using SORT also.
Thanks,
Abhijit. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Good to hear it is working - thank you for letting us know
d |
|
Back to top |
|
|
|