MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

accepting email id from the rexx panel

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
priyaranjan.mishra
Beginner


Joined: 21 Jan 2008
Posts: 17
Topics: 9

PostPosted: Fri Mar 31, 2017 7:17 am    Post subject: accepting email id from the rexx panel Reply with quote

I have a requirement to enter the email ID on the rexx panel for the user and receive it in the REXX exec to use it in a SORT step.

Following is the sort step inside the REXX EXEC:
Code:


QUEUE  "//**********************************************************"
QUEUE  "//**FORMAT EMAIL TO BE SENT TO ONE RECIEPANT             ***"
QUEUE  "//**********************************************************"
QUEUE  "//SORT00  EXEC PGM=SORT                                     "
QUEUE  "//*                                                         "
QUEUE  "//SORTIN   DD DISP=SHR,DSN=TRWTAMR.MAILFMT0                 "
QUEUE  "//*                                                         "
QUEUE  "//SORTOUT  DD DISP=(NEW,CATLG,DELETE),                      "
QUEUE  "//            UNIT=SYSDA,                                   "
QUEUE  "//            DCB=(LRECL=150,RECFM=FB,BLKSIZE=0),           "
QUEUE  "//            SPACE=(TRK,(10,10),RLSE),                     "
QUEUE  "//            DSN=TRWTAMR.MAILFMT1                          "
QUEUE  "//*                                                         "
QUEUE  "//SYSIN    DD *                                             "
QUEUE  " OPTION COPY                                                    "
QUEUE  " OUTREC FINDREP=(IN=C'AAA',OUT=C'"E1"')                     "
QUEUE  "/*                                                          "
QUEUE  "//*                                                         "
QUEUE  "//SYSOUT   DD SYSOUT=*                                      "
QUEUE  "//SYSUDUMP DD SYSOUT=*                                      "
QUEUE  "//SYSPRINT DD SYSOUT=*                                      "


The input is:
Code:

HELO TEST.EMAIL.COM                                                   
MAIL FROM:<AAA>                                                       
RCPT TO:  <AAA>                                                       
DATA                                                                   
FROM:     <AAA>                                                       
TO:       <AAA>                                                       
SUBJECT: KEYED FILE COMPARISON RESULT                                 
Mime-Version: 1.0                                                     
Content-Type: multipart/mixed; boundary="COV.BRFC#"                   
--COV.BRFC#                                                           
                                                                       
Hi,                                                                   
                                                                       
Please find attached the results for keyed file comparison of the files
requested. 


In the o/p, I want to replace 'AAA' with the email ID supplied 'E1' as mentioned in the sort step above. But the SORT step is only considering
the first statement in the SYSIN "OPTION COPY", the second statement for the OUTREC is skipped and hence the sort step ends up only copying the input to the output.
Before executing the step, I have verified with the SAY command in the REXX exec to make sure that I am receiving E1 from the Panel.

Any idea what might be the issue.
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12357
Topics: 75
Location: San Jose

PostPosted: Fri Mar 31, 2017 10:17 am    Post subject: Re: accepting email id from the rexx panel Reply with quote

priyaranjan.mishra wrote:

In the o/p, I want to replace 'AAA' with the email ID supplied 'E1' as mentioned in the sort step above. But the SORT step is only considering
the first statement in the SYSIN "OPTION COPY", the second statement for the OUTREC is skipped and hence the sort step ends up only copying the input to the output.


priyaranjan.mishra,

Do you ever provide feedback on the solutions you receive? or is it always just ask your question , get answer and move on to your next question?

priyaranjan.mishra wrote:

In the o/p, I want to replace 'AAA' with the email ID supplied 'E1' as mentioned in the sort step above. But the SORT step is only considering
the first statement in the SYSIN "OPTION COPY", the second statement for the OUTREC is skipped
and hence the sort step ends up only copying the input to the output.


Well if you paid attention to your OPTION COPY statement and noticed that you have a non-blank character in position 72 and DFSORT treats a non blank character in column 72 as a comment and it is continued on to the next line. So everything after the Option COPY statement is treated as comment

This behavior is explained here

https://www.ibm.com/support/knowledgecenter/SSLTBW_2.1.0/com.ibm.zos.v2r1.icea100/ice2ca_Continuation_lines.htm

Here is the piece of code which shows that. Look where the double quotes ended.

Code:

"//SYSIN    DD *                                             "
QUEUE  " OPTION COPY                                                    "

_________________
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort

www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
priyaranjan.mishra
Beginner


Joined: 21 Jan 2008
Posts: 17
Topics: 9

PostPosted: Mon Apr 03, 2017 1:27 am    Post subject: Reply with quote

Thanks a ton Kolusu,
After making the suggested modifications for the continuation character, I was able to achieve the desired output.

Regards
Priyaranjan
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group