Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Changing a SYSIN Control card in Runtime...

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
swapnilushinde

New User


Joined: 17 Mar 2009
Posts: 30
Location: Bangalore.India

PostPosted: Wed May 20, 2009 2:18 pm    Post subject: Changing a SYSIN Control card in Runtime...
Reply with quote

Hi
I want to change a control card in runtime . I want to change the filename(present in SYSIN card) when the same job runs twice in a day or particular time span. I wanted to know whether changing the control card like this is possible or not and if yes then how can I do it?
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed May 20, 2009 2:46 pm    Post subject:
Reply with quote

What program / utility is being processed
What are you using this program utility to do
What changes do you want to make

Psychic day was yesterday so please post an example of what you have and what you want to change it to.
Back to top
View user's profile Send private message
swapnilushinde

New User


Joined: 17 Mar 2009
Posts: 30
Location: Bangalore.India

PostPosted: Wed May 20, 2009 3:35 pm    Post subject: Changing SYSIN card in rumtime
Reply with quote

HI
I am using SYSIN card for FTP step. I wanted to avoid overwriting of file mentioned in SYSIN after each run. For that I want to change that filename in every next run. The SYSIN for FTP step :
Code:
FTP.abcd.COM                                     
cd cds1                                                 
PUT 'MAINFRAME FILE' FILENAME1.txt   
CLOSE                                                   
QUIT                                                   
                                               

Here I want to change the name FILENAME1 for next run without manually changing it...
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7913
Location: Bellevue, IA

PostPosted: Wed May 20, 2009 3:58 pm    Post subject:
Reply with quote

Quote:
Here I want to change the name FILENAME1 for next run without manually changing it
Okay ... good luck with that.
Back to top
View user's profile Send private message
swapnilushinde

New User


Joined: 17 Mar 2009
Posts: 30
Location: Bangalore.India

PostPosted: Wed May 20, 2009 4:50 pm    Post subject:
Reply with quote

I know this is impossible but just wanted to double check with others...
Back to top
View user's profile Send private message
Douglas Wilder

Active User


Joined: 28 Nov 2006
Posts: 305
Location: Deerfield IL

PostPosted: Wed May 20, 2009 7:44 pm    Post subject:
Reply with quote

You could over-write the dataset containing the FTP Control Cards or use and include in your JCL and over-write the contents of the include. For either of these you may/would need to write back the old contents the next day. Just thinking outside the box.
Back to top
View user's profile Send private message
dominickim

New User


Joined: 28 Feb 2007
Posts: 65
Location: NS, CA

PostPosted: Wed May 20, 2009 8:01 pm    Post subject: Not sure I understood your situation
Reply with quote

Hello Swapnil,

If you know the rule for the FILENAMEs and allowed to change the JCL, why don't you put the new COBOL (or whatever easy for you) step that creates/changes the SYSIN dataset for next FTP run.

Alternatively, COBOL program can execute TSO commands which include FTP, please google it if you want to change the FILENAME dynamically inside of the program.

Thanks,
Back to top
View user's profile Send private message
swapnilushinde

New User


Joined: 17 Mar 2009
Posts: 30
Location: Bangalore.India

PostPosted: Fri May 22, 2009 10:53 am    Post subject: Changing the filename dynamically
Reply with quote

Hi
I have tried to change the filename dynamically in SMTP step using Symbolic variables. Unfortunately we cannot test FTP so may I know whether the same symbolic variables are valid in FTP also.
Here is the manual I referred :
http://www.lbdsoftware.com/XMITIP-Guide.pdf
I tried this thing :
Code:
//S8  EXEC SMTPEMNJ                                       
//SS1.CONTROL DD *                                         
COMMAND   SEND                                             
FROM      FTP@abc.COM                             
TO        SSHINDE@abc.COM                                 
ATTACH   DDN:ATTACH1 &TIME_customer_data.TXT TRANSLATE             
MARGIN    005                                             
SUBJECT   FTP-ATTACH                                       
/*                                                         
//SS1.MESSAGE DD *                                         
          PLEASE FIND ACTUAL PAID REPORT AS ATTACHMENT     
           **DOUBLE CLICK TO 'OPEN' THE ATTACHMENT**       
/*                                                         
//SS1.ATTACH1 DD DSN=filename,DISP=SHR
//*                                                       

I tried to rename the file for each run by &TIME symbolic variable. I want to confirm whether it will work in FTP also....
Back to top
View user's profile Send private message
dominickim

New User


Joined: 28 Feb 2007
Posts: 65
Location: NS, CA

PostPosted: Fri May 29, 2009 3:39 pm    Post subject: I am wondering the issue has been resolved.
Reply with quote

Hello Swapnil,

I am wondering the issue has been resolved.
Have you tried that Douglas and I suggested?

Thanks,
Dominic
Back to top
View user's profile Send private message
swapnilushinde

New User


Joined: 17 Mar 2009
Posts: 30
Location: Bangalore.India

PostPosted: Fri May 29, 2009 7:23 pm    Post subject: Reply to: Changing a SYSIN Control card in Runtime...
Reply with quote

Hi dominickim,
We cannot test FTP in test region. We are trying to get access for it.. That's why I want some surety that same symbolic variable will work in FTP also so that I can persuade upper management for access.
Please let me know whether it will work in FTP or not??
Thanks for your suggestion...
Back to top
View user's profile Send private message
dominickim

New User


Joined: 28 Feb 2007
Posts: 65
Location: NS, CA

PostPosted: Fri May 29, 2009 9:18 pm    Post subject: I'd say no with above code
Reply with quote

Hello Swapnil,

First of all, the &TIME is not valid symbolic name.
Second, symbolic variables can not be overwritten if it placed inside of SYSIN cards that system does not consider as part of JCL.

Thanks,
Dominic
Back to top
View user's profile Send private message
abin

Active User


Joined: 14 Aug 2006
Posts: 198

PostPosted: Sat May 30, 2009 3:29 am    Post subject:
Reply with quote

This is a method commonly followed in my shop.

Step 0. Delete temporary FTP file
Step 1. Read the FTP card and change the file name and write into a temporary FTP file.
Step 2. FTP using temporary file.
Back to top
View user's profile Send private message
abin

Active User


Joined: 14 Aug 2006
Posts: 198

PostPosted: Sat May 30, 2009 3:30 am    Post subject:
Reply with quote

Step 1. Read the FTP card and change the file name and write into a temporary FTP file.

This step needs to be done using a program or a sort card or whatvere normal data processing utility.
Back to top
View user's profile Send private message
dominickim

New User


Joined: 28 Feb 2007
Posts: 65
Location: NS, CA

PostPosted: Sat May 30, 2009 9:29 pm    Post subject:
Reply with quote

Hello Abin,

That's exactly what we are using, too and I suggested earlier.
Thanks for your details.

Thanks,
Dominic
Back to top
View user's profile Send private message
karthik_sripal

New User


Joined: 28 Mar 2008
Posts: 67
Location: 125.16.180.5

PostPosted: Sun May 31, 2009 12:00 pm    Post subject:
Reply with quote

This is exactly an issue we faced sometime back,

what we have done is we generated the FTP control card having date and time appended to the destination file name like the one below shown below
using a sort card

Code:

FTP.abcd.COM                                     
cd cds1                                                 
PUT 'MAINFRAME FILE' FILENAME1.date.time.txt
CLOSE                                                   
QUIT                                                   
     


I can share the code happily used if required, please write back icon_smile.gif
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Sun May 31, 2009 12:09 pm    Post subject: Reply to: Changing a SYSIN Control card in Runtime...
Reply with quote

Quote:
I can share the code happily used if required, please write back
Please do.

Your solution will later help someone else with a similar question as well as people already participating in this topic icon_smile.gif

d
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2163
Location: @my desk

PostPosted: Mon Jun 01, 2009 5:46 pm    Post subject: Re: Reply to: Changing a SYSIN Control card in Runtime...
Reply with quote

Hi Dick,

This is what we use here.

FTP card
Code:
----+----+----+----+----+----+----+----+----+----+----+
cd /aaa/bbbb/cccc/dddd/eee/
TYPE A                                                           
ASCII                                                             
put 'SOME.MAINFRAM.FILE1(+0)'  +                         
             SOME_FILE_NAME1_             
put 'SOME.MAINFRAM.FILE2(+0)'  +                                 
             SOME_FILE_NAME2_               
put 'SOME.MAINFRAM.FILE3(+0)'  +                                 
             SOME_FILE_NAME3_               
close                                                             
quit

Sort step before FTP
Code:
  SORT FIELDS=COPY                                                     
  INREC IFTHEN=(WHEN=(1,3,CH,EQ,C'   '),OVERLAY=(30:&DATE4,49:C'.csv'))
SORT Output
Code:
cd /aaa/bbbb/cccc/dddd/eee/                         
TYPE A                                             
ASCII                                               
put 'SOME.MAINFRAM.FILE1(+0)'  +                   
             SOME_FILE_NAME1_2009-06-01-05.22.44.csv
put 'SOME.MAINFRAM.FILE2(+0)'  +                   
             SOME_FILE_NAME2_2009-06-01-05.22.44.csv
put 'SOME.MAINFRAM.FILE3(+0)'  +                   
             SOME_FILE_NAME3_2009-06-01-05.22.44.csv
close                                               
quit                                               
Back to top
View user's profile Send private message
swapnilushinde

New User


Joined: 17 Mar 2009
Posts: 30
Location: Bangalore.India

PostPosted: Tue Jun 02, 2009 12:50 pm    Post subject: Reply to: Changing a SYSIN Control card in Runtime...
Reply with quote

HI Karthik
thanks a lot for your valuable reply. That's the thing I wanted to do. Please share the more information regarding this and if possible please send some manuals or PDF's.
Once again thanks..
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. How to use 2 input files in control c... Gunapala CN DFSORT/ICETOOL 23 Thu Oct 13, 2016 3:42 pm
This topic is locked: you cannot edit posts or make replies. Sort card to replace text using cross... Susanta SYNCSORT 32 Tue Sep 13, 2016 4:17 pm
No new posts Creating a dynamic sort card in JCL u... ChitraChhabra DFSORT/ICETOOL 4 Wed Aug 03, 2016 6:15 pm
No new posts Need to know what sysin for DFHTU690 ... pkmurali CICS 3 Mon Jul 25, 2016 1:36 pm
No new posts changing z/os unicode conversion service meykh2014 All Other Mainframe Topics 0 Tue Jul 12, 2016 10:49 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us