View previous topic :: View next topic |
Author |
Message |
radkrish Beginner
Joined: 12 Aug 2005 Posts: 102 Topics: 19
|
Posted: Fri Aug 12, 2005 4:29 am Post subject: Change of file name at receiving end in FTP step |
|
|
FTP parameters:
my control card has
*ip*
*user*
*pw*
put 'AAA.BBBB' CCC.txt (the file name is to be suffixed with datetimestamp and it should be changed for each run of the job.The name should look like CCC200508121250 and the next day it should be CCC20050813121206 and so on....)
quit
Give me your suggestions whether i could change it on JCL side.no problem if change should be in the program(pls provide the code).
_________________
regds,
radkrish |
|
Back to top |
|
|
Cogito-Ergo-Sum Advanced
Joined: 15 Dec 2002 Posts: 637 Topics: 43 Location: Bengaluru, INDIA
|
Posted: Fri Aug 12, 2005 7:23 am Post subject: |
|
|
Please search before posting.
You can build on Kolusu's posts in these threads.
FTP date 1
FTP date 2 _________________ ALL opinions are welcome.
Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes. |
|
Back to top |
|
|
Bithead Advanced
Joined: 03 Jan 2003 Posts: 550 Topics: 23 Location: Michigan, USA
|
Posted: Fri Aug 12, 2005 7:40 am Post subject: |
|
|
I like this one:
Code: |
//BUILDCMD EXEC PGM=EZACFSM1
//SYSPRINT DD SYSOUT=*
//SYSOUT DD DSN=&CMD,DISP=(NEW,PASS).... <=LRECL=80
//SYSIN DD *
*ip*
*user*
*pw*
PUT CCC&LYR4&LMON&LDAY&LHR&LMIN&LSEC..TXT
QUIT
//*
//FTPSTEP EXEC PGM=FTP.....(parms)
//SYSPRINT DD SYSOUT=*
//INPUT DD DSN=&CMD,DISP=(OLD,DELETE)
//OUTPUT DD SYSOUT=*
//*
|
|
|
Back to top |
|
|
Cogito-Ergo-Sum Advanced
Joined: 15 Dec 2002 Posts: 637 Topics: 43 Location: Bengaluru, INDIA
|
Posted: Fri Aug 12, 2005 7:42 am Post subject: |
|
|
Bithead,
Is EZACFSM1 a shop specific Pgm? I have not come across it. _________________ ALL opinions are welcome.
Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes. |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12369 Topics: 75 Location: San Jose
|
|
Back to top |
|
|
Cogito-Ergo-Sum Advanced
Joined: 15 Dec 2002 Posts: 637 Topics: 43 Location: Bengaluru, INDIA
|
Posted: Fri Aug 12, 2005 8:26 am Post subject: |
|
|
Kolusu,
I know about EZACFSM1. But, I was unsure when I saw its usage as a PROC rather than a program. _________________ ALL opinions are welcome.
Debugging tip:
When you have eliminated all which is impossible, then whatever remains, however improbable, must be the truth.
-- Sherlock Holmes. |
|
Back to top |
|
|
radkrish Beginner
Joined: 12 Aug 2005 Posts: 102 Topics: 19
|
Posted: Tue Aug 16, 2005 3:17 am Post subject: |
|
|
It works well but it gives FTP Return Code = 99000. |
|
Back to top |
|
|
radkrish Beginner
Joined: 12 Aug 2005 Posts: 102 Topics: 19
|
Posted: Tue Aug 16, 2005 3:30 am Post subject: |
|
|
The ftp return code is because of that I have given a lengthier filename on the ftp parm which exceeds 72 char on the same line.So i have to continue in the next line.Can anyone please let me know how to continue to the next line in the parm.
eg.;
put 'aaaa.bbbb.txt' WQX07R1-&LYR4. &LMON.&LDAY.&LHR.&LMIN. &LSEC..CSV
(which forces to enter continuation in the next line).
Hence it results in error. |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12369 Topics: 75 Location: San Jose
|
|
Back to top |
|
|
radkrish Beginner
Joined: 12 Aug 2005 Posts: 102 Topics: 19
|
Posted: Tue Aug 16, 2005 4:26 am Post subject: |
|
|
Yes.I got it.Thanks for all your replies. |
|
Back to top |
|
|
radkrish Beginner
Joined: 12 Aug 2005 Posts: 102 Topics: 19
|
Posted: Wed Aug 17, 2005 12:31 am Post subject: |
|
|
If i want to add milliseconds on to &LHR.&LSEC,what should i use here to get it?
Is that possible in this way? |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12369 Topics: 75 Location: San Jose
|
|
Back to top |
|
|
radkrish Beginner
Joined: 12 Aug 2005 Posts: 102 Topics: 19
|
Posted: Thu Aug 18, 2005 11:36 pm Post subject: |
|
|
The idea works well.Thanks,Kolusu. |
|
Back to top |
|
|
|
|