[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Is there a way to obtain the system date when executing the IBM FTP?

Posted on 2011-03-14
1
Medium Priority
?
1,405 Views
Last Modified: 2013-12-09
When running a EXEC=FTP on the mainframe, executing the IBM program called FTP is there a way to obtain the system date and then use the system date as part of the file name?
For example, in the following PUT statement, I need to obtain the current date YYYYMMDD:
PUT 'mainframe.file(0)'   YYYYMMDD_server_filename.TXT
 
0
Comment
Question by:preferredbooks
1 Comment
 
LVL 57

Accepted Solution

by:
giltjr earned 2000 total points
ID: 35128301
A couple of possibilities:

1) If you have a job scheduler typically they have the ability to have variables in the JCL and fill in.  We do this with BMC's Control-M all of the time.  I am sure that other job schedulers have the same featuer/function.

2) Instead of executing FTP in batch, you could setup a REXX that calls FTP and the REXX can get the system date/time and pass everything to FTP.

3) TCP/IP provides a program, EZACFSM1, that you can feed your JCL into and it will resove any system symbols you have coded in it and then you submit the job to the internal reader.

I'm not sure if there is a system symbol for YYYYMMDD, but you could use:

     &YR4.&MON.&DAY

to build it.  The above will get you the date based on GMT time.  If you want local time you would need to use:

      &LYR4.&LMON.&LDAY
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

With the withdrawal of support for Windows Server 2003 this summer, many clients face the issue of moving away from their 2003 installs. There are a few options out there that many people/companies are selling. But the clients I have, haven't wanted…
As a financial services provider, your business is impacted by two of the strictest federal regulations on record: the Sarbanes-Oxley Act and the Gramm-Leach-Bliley Act. Correctly implementing faxing into your organization to provide secure, real-ti…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
Suggested Courses
Course of the Month18 days, 5 hours left to enroll

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question