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
 

 

To Find If A Member Of PDS is Empty

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
vikramp

New User


Joined: 31 May 2007
Posts: 3
Location: chennai,andhrapradesh,india

PostPosted: Wed Oct 03, 2007 8:08 pm    Post subject: To Find If A Member Of PDS is Empty
Reply with quote

Hi,

Is there is any way to find if a member of a PDS is empty through REXX.

I have a requirement in the project where i need to check if the member of PDS is empty and if some one trys to open it in browse mode, i need to throw some error message. Can anybody help me with this please....?
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Wed Oct 03, 2007 8:15 pm    Post subject: Reply to: To Find If A Member Of PDS is Empty
Reply with quote

Why do not try it Yourself ? :-)

You will see that ISPF will throw a nice error message

regards

e.s
Back to top
View user's profile Send private message
vikramp

New User


Joined: 31 May 2007
Posts: 3
Location: chennai,andhrapradesh,india

PostPosted: Wed Oct 03, 2007 8:43 pm    Post subject: Reply to: To Find If A Member Of PDS is Empty
Reply with quote

no,

I need to throw a custom error message, because it throws an ispf error message it closes the screen and i don't want that. can any one tell me a way out of this pleaseeee...?
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Wed Oct 03, 2007 8:47 pm    Post subject: Reply to: To Find If A Member Of PDS is Empty
Reply with quote

Can't you attempt to read (via EXECIO) 1 record from the member, and check whether it was successful or not?
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Wed Oct 03, 2007 8:48 pm    Post subject:
Reply with quote

Do you want to do it programmatically, or anytime a user enters a member? If the later, use an organizational Initial Edit Macro.

O.
Back to top
View user's profile Send private message
vikramp

New User


Joined: 31 May 2007
Posts: 3
Location: chennai,andhrapradesh,india

PostPosted: Wed Oct 03, 2007 8:55 pm    Post subject: Reply to: To Find If A Member Of PDS is Empty
Reply with quote

thanks superk & ofer71,

i could try the EXECIO command. i think it might work.

thanks a lot.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Wed Oct 03, 2007 9:05 pm    Post subject: Reply to: To Find If A Member Of PDS is Empty
Reply with quote

Also, I'm thinking, wouldn't the ISPF Services LMMLIST with STATS(YES) variable for ZLCNORC (Current number of records) (if value is zero) be useful?
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Wed Oct 03, 2007 9:21 pm    Post subject: Reply to: To Find If A Member Of PDS is Empty
Reply with quote

Quote:
because it throws an ispf error message it closes the screen and i don't want that


I do not answer questions without checking

I checked again and YOU ARE JUST PLAIN WRONG,

it does not close the screen

ISPF issues the message "ISRB107" and sits there waiting for YOU to press the PF1 key in order to see the long message.

if You are using a dialog
without "CONTROL ERRORS RETURN"
ISPF will display a dialog error panel with msg ISRB107

with "CONTROL ERRORS RETURN"
ISPF will do nothing and let You handle the error

in both cases the return code from
"BROWSE DATSET(your.empty.dataset)"
will be 12

regards

e.s
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts find particular member name in PDS us... ravi243 CLIST & REXX 10 Mon Dec 19, 2016 6:44 pm
No new posts How to find the first monday of the w... abdulrafi COBOL Programming 10 Fri Nov 25, 2016 3:24 pm
No new posts What is the command to check MODE of ... rohanthengal CLIST & REXX 7 Fri Nov 18, 2016 1:48 pm
No new posts Find out a active PGM jpsager JCL & VSAM 10 Fri Oct 07, 2016 4:32 pm
No new posts How to find a CICS resource used in C... Arunkumar Chandrasekaran CICS 8 Thu Sep 29, 2016 1:45 pm


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