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
 

 

Can we change the parm card

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
Venkata Ramayya

New User


Joined: 03 Dec 2007
Posts: 39
Location: United States

PostPosted: Thu Dec 06, 2007 10:08 pm    Post subject: Can we change the parm card
Reply with quote

I have two parm cards

Parm card 1 - *
*
97 - 3rd record

Parm card 2 - DEMAND,JOB=AAAAAAAA,SCHID=99
/LOGOFF

I have to keep '97' from the Parm card 1 to the postion of '99' in the Parm card 2.

Output of Parm card 2 should be

DEMAND,JOB=AAAAAAAA,SCHID=97
/LOGOFF

Thanks
Venkat
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: Fri Dec 07, 2007 12:24 am    Post subject:
Reply with quote

Hello Venkat and welcome to the forums,

Is this a sort question?

Please post some(?) of your actual input records and the output you want from the posted input.

Please also include the recfm and lrecl of the file(s).

A more clear definition of your requirement will also work in your favor.
Back to top
View user's profile Send private message
Venkata Ramayya

New User


Joined: 03 Dec 2007
Posts: 39
Location: United States

PostPosted: Fri Dec 07, 2007 12:47 am    Post subject: Reply to: Can we change the parm card
Reply with quote

Thanks for quick response.

I do not say it is a sort question. How can we go without program?

Parm card 1 - it is a member of dataset, the value on 11th row varies based on special case. I need to take this value '97' from 11th row of the Parm card 1 and keep in Parm card 2

0004 * SCHID VALUE SPECIAL CASE
0005 * ----------- ------------
0006 * 97
0007 *
0008 * 98
0009 *
0010 *---+----1----+----2----+----3----+----4----+----5----+----6----+----
0011 97

Parm card 2 -
000001 DEMAND,JOB=XXXXXXXX,SCHID=99
000002 /LOGOFF

Please note Parm card 1 and 2 are members of PDS. I should update the Parm card 2 as
000001 DEMAND,JOB=XXXXXXXX,SCHID=97
000002 /LOGOFF

Can we input Parm card 1 and 2 to some utility and update Parm card2?

Thanks
Venkat
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: Fri Dec 07, 2007 1:43 am    Post subject:
Reply with quote

Hello,

Quote:
I do not say it is a sort question
Posting the question in DFSORT/ICETOOL implies a sort question.

Quote:
How can we go without program?
Even without a program, there will still have to be jcl and documentation and probably the process "promoted" to production.

How often will this process be done? Will parm card 1 and parm card 2 always have the same number of lines? Will there ever be more than one value to (i.e. 97) work with? Will the values always be in the same positions in the line?

As we learn more about what your requirement really is, we may have more questions.
Back to top
View user's profile Send private message
Venkata Ramayya

New User


Joined: 03 Dec 2007
Posts: 39
Location: United States

PostPosted: Fri Dec 07, 2007 2:14 am    Post subject: Reply to: Can we change the parm card
Reply with quote

Posting the question in DFSORT/ICETOOL implies a sort question.- As I am the new user so I did not know this.

This process is done for every quater.
Yes, Parm card 1 and 2 have same number of lines always. In the parm card 1 can have two values either 97 or 98 in the same position (11th row, column 1 and 2). The value in the parm card 1 would be entered by the user for every quarter.

Whenver the use enters the value(97 or 98) that value should be reflected on parm card 2
000001 DEMAND,JOB=XXXXXXXX,SCHID=97
000002 /LOGOFF

Thanks
Venkat
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Fri Dec 07, 2007 3:53 am    Post subject:
Reply with quote

Venkat,

You can use a DFSORT job like the following to do what you asked for. I assumed the value in parm card 1 you want is in positions 1-2 of the 11th record. I assumed the value you want to replace in parm card 2 is in positions 27-28 of the record with 'SCHID=' starting in position 21. You can change the job as needed.

Code:

//S1    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SORTIN DD DSN=userid.pds(m1),DISP=SHR
//SORTOUT DD DSN=&&S1,UNIT=SYSDA,SPACE=(TRK,(1,1)),DISP=(,PASS)
//SYSIN    DD    *
  OPTION COPY,SKIPREC=10
  OUTREC BUILD=(C'TARG,''',1,2,C'''',80:X)
/*
//S2    EXEC  PGM=ICEMAN
//SYSOUT    DD  SYSOUT=*
//SYMNAMES DD DSN=&&S1,DISP=(OLD,PASS)
//SORTIN DD DSN=userid.pds(m2),DISP=SHR
//SORTOUT DD DSN=userid.pds(m3),DISP=OLD
//SYSIN    DD    *
  OPTION COPY
  INREC IFTHEN=(WHEN=(21,6,CH,EQ,C'=SCHID'),OVERLAY=(27:TARG))
/*
Back to top
View user's profile Send private message
Venkata Ramayya

New User


Joined: 03 Dec 2007
Posts: 39
Location: United States

PostPosted: Sat Dec 08, 2007 12:25 am    Post subject: Reply to: Can we change the parm card
Reply with quote

Hi Frank,

It worked out. Thanks a lot!!

I have one question in the first step

OUTREC BUILD=(C'TARG,''',1,2,C'''',80:X).
Can you please explain me the each parameter in the above syntax?

Thanks
Venkat
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Sat Dec 08, 2007 12:38 am    Post subject:
Reply with quote

Code:

   OUTREC BUILD=(C'TARG,''',1,2,C'''',80:X).


This OUTREC statement builds an 80-byte DFSORT Symbol record of the form:

TARG,'xx'

C'TARG,''' - builds a constant of TARG, and a starting apostrophe -> TARG,' -> Note that we need '' to get ' inside the character constant.

1,2 - copies the characters from input positions 1-2 (e.g. 97)

C'''' - builds the ending apostrophe

80:X - pads with blanks from after the ending apostrophe up to and including position 80 (gives us an 80-byte record).

If you're not familiar with DFSORT and DFSORT's ICETOOL, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html
Back to top
View user's profile Send private message
Venkata Ramayya

New User


Joined: 03 Dec 2007
Posts: 39
Location: United States

PostPosted: Sat Dec 08, 2007 12:56 am    Post subject: Reply to: Can we change the parm card
Reply with quote

Frank,

Thanks for great explanation and suggestion too.

Thanks
Venkat
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Sat Dec 08, 2007 1:47 am    Post subject:
Reply with quote

Glad I could help.
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Sort Card to Remove Duplicate records... raj4neo SYNCSORT 2 Wed Jan 25, 2017 4:44 am
No new posts Fail to change physical VSAM filename... jacobdng CICS 7 Fri Jan 20, 2017 12:36 pm
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 Change date (DD/MM/YY) in 2nd record ... uday kiran DFSORT/ICETOOL 12 Wed Sep 07, 2016 10:57 pm


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