Coding "PIPE CMS xxx" is exactly the same as coding "address CMS 'xxxx ..." That is, CMS performs the full command resolution, and an EXEC will get selected instead of a MODULE. Therefore it is recommended to use address COMMAND and PIPE COMMAND. Even more: you should not abbreviate a CMS command, this to avoid user defined synonyms, so do *not* code PIPE COMMAND L * EXEC A ... but PIPE COMMAND LISTFILE * EXEC A ...
Then and only then you are sure that an unexpected EXEC or synonyms makes you exec do something else than expected. Lesson 1, chapter 3 in this self study "TeleCourse" explains it in great detail http://www.vm.ibm.com/download/packages/descript.cgi?TCVM1 So, I am pretty sure your PIPE CMS invokes the TELNET EXEC, not the MDOULE. For your TELNET case: /* your exec */ address command /* Be sure to execute what we need */ 'PIPE COMMAND EXEC TELNET .... 2009/7/13 Gentry, Stephen <[email protected]> > > (I tried to post this to the cms pipes list but it was rejected) > > > > I have a simple EXEC that pipes the output of the NETSTAT command to a stem. > > If I issue NETSTAT in a normal CMS session, I get the results back that I > expect. > > When run it in an EXEC containing a PIPE, I get errors from the NETSTAT > command. > > Code: PIPE CMS NETSTAT TELNET | stem myStem. > > There two files with the name NETSTAT, one is a MODULE the other an EXEC. > When I run > > It from a CMS session, the EXEC gets invoked but when I run it from and EXEC > I wrote > > containing the PIPE command above it seems to invoke the MODULE. > > Is that the way PIPES work? I thought the CMS param set the environment. > > Any thoughts? > > Thanks, > > Steve > > -- Kris Buelens, IBM Belgium, VM customer support
