Page 1 of 1

symbolic parameter.

Posted: Sun Sep 07, 2014 10:34 pm
by DEVAPRIYA
hi,

i have a data in particular pds member below.
pds: DEVA.ACCESS(DATE)
date('1408')

in another PDS member (accept) i am using the above dataset.

Code: Select all

//xxxx exec accept
//accept proc
//XXXX EXEC IEBGENER
//SYSUT1 DD DSN=DEVA.ACCESS(DATE),DISP=SHR
//SYSUT2 DD DSN=&&TEMP,DISP=(NEW,PASS)
//SYSIN DD DUMMY
//
i want to update the current date value in DEVA.ACCESS(DATE) daily ..is there any method that automatically take the current o date directly while submitting the job with out manual change..

or is it possible to change date in (accept) proc jcl using symbolic value with out accessing access dataset.

please help me.

Re: symbolic parameter.

Posted: Sun Sep 07, 2014 10:57 pm
by Anuj Dhawan
Hi Devapriya,

The date you need is in YYMMform? You don't need the day?

And what SORT product are you using at your shop?

Re: symbolic parameter.

Posted: Sun Sep 07, 2014 11:39 pm
by DEVAPRIYA
Hi Anuj,

I need only YYMM alone..i don't want date..

And what SORT product are you using at your shop?
i can't get you wat u r asking for...

Re: symbolic parameter.

Posted: Mon Sep 08, 2014 2:24 am
by Robert Sample
And what SORT product are you using at your shop?
i can't get you wat u r asking for...
The question is a simple one -- are you using DFSORT, or SYNCSORT, or CA-SORT, or some other sort product? And the reason for asking is that what you are wanting to do is usually done through the sort product, and the particulars will vary depending upon which sort product your site has installed.

Re: symbolic parameter.

Posted: Mon Sep 08, 2014 11:08 am
by Anuj Dhawan
Hello Devpriya,

Assuming:
  • you want date in position 1 in a RECFM=FB and LRECL=80 byte and
  • the SORT product at your shop supports the DATE2 function , use the following SORT JCL:

Code: Select all

//STEP01 EXEC PGM=SORT
//SYSOUT   DD SYSOUT=*
//SORTIN   DD *
dummy
//SORTOUT  DD SYSOUT=*
//SYSIN    DD *
  OPTION COPY
  INREC IFOUTLEN=80,
        IFTHEN=(WHEN=INIT,OVERLAY=(81:DATE2,1:83,4))
//*
Change SORTOUT as per your need.

As Robert has said, I've assumed that you can use the SORT to achieve what you need. However, I think (though I've not tested it) - that you can make use of symbol converter EZACFSM1 as well.

OTOH, to know what SORT product is in use at your shop - look for message's prefix in the SYSOUT of any recently executed SORT job -- if you see WERxxxx - it's SyncSort, if it's ICExxx - it's DFSORT; if there is something else you need to tell us what is that.

Re: symbolic parameter.

Posted: Tue Sep 09, 2014 6:14 pm
by DEVAPRIYA
is it possible to use these symbolic parameter &LMON AND &LYR2 in to the dataset value

pds: DEVA.ACCESS(DATE)
date('1408')

Re: symbolic parameter.

Posted: Tue Sep 09, 2014 6:29 pm
by Anuj Dhawan
DEVAPRIYA wrote:is it possible to use these symbolic parameter &LMON AND &LYR2 in to the dataset value

pds: DEVA.ACCESS(DATE)
date('1408')
I'm somewhat confused with your statement - is it in continuation with your original question? As first statement in your this post relates to EZACFSM1 but why do you again write the PDS name?

To answer your first statement - "&LMON" AND "&LYR2" can be used as dataset nodes (I think by "dataset value" you actually mean nodes) for a job executing EZACFSM1. This lists the supported Dynamic System Symbols.

Re: symbolic parameter.

Posted: Tue Sep 09, 2014 6:46 pm
by DEVAPRIYA
what will be the result if i give date("&LMON&YR2")..

if it wont work so..can you please provide me the syntax using EZACFSM1 for this process.
moreover i dont have any testing id..Please do the needful....
Thanks in advance..

Re: symbolic parameter.

Posted: Tue Sep 09, 2014 6:53 pm
by DEVAPRIYA
Anuj,

can you please provide me the jcl using EZACFSM1 to my request..

Re: symbolic parameter.

Posted: Tue Sep 09, 2014 9:23 pm
by Anuj Dhawan
If I got the correct inference of what you want, try this (untested):

Code: Select all

//DATEJCL JOB ,'DATEJCL',CLASS=F,MSGCLASS=1,    
//         NOTIFY=&SYSUID,
//STEP00   EXEC PGM=EZACFSM1                  
//SYSIN    DD DATA,DLM=@@                      
//RUNJ JOB ,'##JCL',CLASS=F,MSGCLASS=1, 
//         NOTIFY=&SYSUID,REGION=4096K        
//STEP01   EXEC PGM=IEFBR14                    
//SYSUT2   DD  DSN=XXXX.XXX.D&LYR2&LMON,        
//             DISP=(NEW,CATLG,DELETE),        
//             UNIT=SYSDA,RECFM=FB,LRECL=80, 
//             SPACE=(CYL,(1,1),RLSE)          
@@                                            
//SYSOUT   DD SYSOUT=(*,INTRDR),LRECL=80,BLKSIZE=80,BUFNO=1,RECFM=F  

Re: symbolic parameter.

Posted: Tue Sep 09, 2014 10:19 pm
by DEVAPRIYA
Thanks Anuj,
this pgm is to create a dataset as deva.access.d1408
Let me clear up my que..
I have a fixed pds dataset with member: DEVA.ACCESS(DATE) inside i have a statement/record as:

000001 date('YYMM')
000002 END

i need to update the value of YYMM with current year/month automatically...when i am submitting the above IEBGENER program.

Re: symbolic parameter.

Posted: Tue Sep 09, 2014 10:36 pm
by nicc
Then you will need a program to red the dt, update it and write to anothe dataset.

If your data is instream i.e. after a DD * AND you are using the ltest z/OS then you can use symbolics in your data.

Re: symbolic parameter.

Posted: Wed Sep 17, 2014 9:46 pm
by DEVAPRIYA
Hi Guys.

i tried using sort program below

//STEP01 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=DEVA.ACCESS(DATE),DISP=SHR
//SORTOUT DD DSN=DEVA.ACCESS(M1),DISP=SHR
//SYSIN DD *
OPTION COPY
INREC IFOUTLEN=80,
IFTHEN=(WHEN=INIT,OVERLAY=(81:DATE2,1:83,4))
//*
//

i got an output as the date when the member of M2 is created and i am not getting the current date.
input:
DATE('YYMM')
END
i got an output as
DATE('YYMM')
END YYMM --yymm as date when dataset M2 is created.

Please have a look and advice on it..

Re: symbolic parameter.

Posted: Thu Sep 18, 2014 12:43 am
by DEVAPRIYA
Hi anuj ,
can you please help me when i run the below program i got the current date in my output as
PARMS('1409')
END 1409

BUT I NEED OUTPUT AS
PARMS('1409')
END

I TRIED INREC OVERLAY=(10:DATE2) BUT I AM GETTING VALUE AS PARMS('201409
PLEASE HELP ME TO GET MY EXECAT OUTPUT

//STEP01 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=DEVA.ACCESS(DATE),DISP=SHR
//SORTOUT DD DSN=DEVA.ACCESS(M1),DISP=SHR
//SYSIN DD *
OPTION COPY
INREC IFOUTLEN=80,
IFTHEN=(WHEN=INIT,OVERLAY=(81:DATE2,1:83,4))
//*
//

Re: symbolic parameter.

Posted: Thu Sep 18, 2014 8:24 am
by Anuj Dhawan
Hello Devpriya,

I see that you've made two posts but deleted them later - did you get it working for you?

Re: symbolic parameter.

Posted: Sat Sep 20, 2014 12:50 am
by DEVAPRIYA
Hi Anuj,

Ya i used DFSORT with DATE2 parameter as robert said it worked fine.

Thanks for help guys.

Re: symbolic parameter.

Posted: Sat Sep 20, 2014 11:02 am
by Anuj Dhawan
Great that you've got it working for you. :)

If possible, please post the final solution you've used - it might help someone in future.

Re: symbolic parameter.

Posted: Thu Sep 25, 2014 4:22 pm
by Piggy Chop
If possible can you please share your solution?