Unix "which" command equivalent for MVS ?

Mike Stramba <[email protected]> Mon, 21 Jun 2010 12:21:36 -0400
Newsgroups gmane.comp.emulators.turnkey-mvs
Message-ID <[email protected]>
*nix has a handy command "which".

From the man page :

 which [options] [--] programname [...]

Which takes one or more arguments. For each of its arguments it prints
       to stdout the full path of the executables that would have been exe-
       cuted when this argument had been entered at the shell prompt. It does
       this by searching for an executable or script in the directories listed
       in the environment variable PATH using the same algorithm as bash(1).

Is there an equivalent command for MVS?

If not how would I write one?

I'm reading through 'ABC's of System Programming for OS390', and VOl
#2, Chapter 4 "LPA, LNKLST, authorized libraries", and chapter 1,
"IPL" have been helpful, in my attempt to understand how MVS searches
for executables.

There seem to be  similarities with it and MVS38j (lnklst ...etc), but
there are enough differences to pose a few "challenges" ;)

Mike