Re: [CMS-PIPELINES] Inline Rexx?

2021-07-06 Thread Michael Harding
Sort of inline

'PIPE (End ?)',
...
'|a:Rexx *.1:',
...
'?Literal /* */
...l rexx filter code ...
'| a:'


--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-4403 (o)
(925) 323-2070 (m)
(925) 672-3922 (h)
/sp


"CMSTSO Pipelines Discussion List"  wrote on
07/06/2021 02:33:05 PM:

> From: "Paul Gilmartin" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/06/2021 02:33 PM
> Subject: [EXTERNAL] Inline Rexx?
> Sent by: "CMSTSO Pipelines Discussion List" 
>
> Is there a way to code a Rexx filter in a pipe specification rather
> than supplying it as FN FT FM?  I'm imagiining something such as:
> ... | REXX (INLINE) "outpot  translate( 'abcd-ef-gh', date
> (Standard), 'abcdefgh') time(Normal)" | console
> which might produce:
> 2021-07-06 15:17:27
>
> (It's just an example; I'm not looking for specific Pipelines code.)
>
> I suspect there are built-in stages to do this, but I know Rexx
> better than SPECS.  And some things are still done better
> outside PipeThink.
>
> -- gil


Re: [CMS-PIPELINES] Question about starsys *vmevent handling......

2021-04-15 Thread Michael Harding
I think Rob hit the nail on the head. STARSYS tries a 2-way IUCV connection
but *VMEVENT is 1-way. You should be using STARMSG instead as it's also
1-way.

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-4403 (o)
(925) 323-2070 (m)
(925) 672-3922 (h)
/sp


CMSTSO Pipelines Discussion List  wrote on
04/15/2021 07:34:18 AM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 04/15/2021 07:34 AM
> Subject: [EXTERNAL] Re: Question about starsys *vmevent handling..
> Sent by: CMSTSO Pipelines Discussion List 
>
> On Thu, 15 Apr 2021 at 16:32, Rob van der Heij  wrote:
>
> > On Thu, 15 Apr 2021 at 16:16, John P. Hartmann 
wrote:
> >
> >> Please trace IUCV to see the interrupt parameter and message number.
> >>
> >
> > I see it as well, and I'm trying to remember what I'm doing wrong,
since
> > folks are using CMS Pipelines to catch VMEVENT stuff...
> >
>
> And I know, you use STARMSG to catch them!
>
> Sir Rob the Plumber
>


Re: [CMS-PIPELINES] swap two records

2019-08-14 Thread Michael Harding
Not so. Pick will pass the target and next record and fire off again the
next time the target is recognized.

t pt data
PT DATA A1 as of 08/14/19 11.02.42

  record 1
  record 2
tg tagged 1
  record 4
  record 5
  record 6
tg tagged 2
  record 7
  record 8
  record 9

Ready; T=0.01/0.01 13:35:53
pipe < pt data|rexx pt|cons
  record 2
  record 1
  record 4
tg tagged 1
  record 6
  record 5
  record 7
tg tagged 2
  record 9
  record 8
Ready; T=0.01/0.01 13:36:27



--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-3922 | (925) 672-4403 (h)
(925) 323-2070 (m)
/sp


CMSTSO Pipelines Discussion List  wrote on
08/14/2019 11:22:45 AM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 08/14/2019 11:23 AM
> Subject: [EXTERNAL] Re: swap two records
> Sent by: CMSTSO Pipelines Discussion List 
>
> On Wed, 14 Aug 2019 at 20:18, Michael Harding 
wrote:
>
> > Perhaps simpler, as a rexx stage:
> >
> > '|a:Pick anycase from 1+ == /'tag'/ count 2',
>
>
> Notice that PICK will do the trick only once for the entire stream. I
read
> Mike's "now and then" as multiple swapped records in a single stream, so
> that's why I opted for BETWEEN instead.
>
> Sir Rob the Plumber
>
> >
> >
>


Re: [CMS-PIPELINES] swap two records

2019-08-14 Thread Michael Harding
Perhaps simpler, as a rexx stage:

Parse arg tag .
'CallPipe (End ?) *:',
'|a:Pick anycase from 1+ == /'tag'/ count 2',
'|Spec a: 1-* . set #0:=a read 1-* n write print #0 1',
'|b:Faninany',
'|*:',
'?a:|b:'
Exit Rc




--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-3922 | (925) 672-4403 (h)
(925) 323-2070 (m)
/sp


CMSTSO Pipelines Discussion List  wrote on
08/14/2019 09:49:43 AM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 08/14/2019 09:50 AM
> Subject: [EXTERNAL] Re: swap two records
> Sent by: CMSTSO Pipelines Discussion List 
>
>   | x: if between /tag/ 2
>   | spec 1-* c2x
>   | join / /
>   | spec w2 1 w1 nw
>   | split
>   | spec 1-* x2c
>   | x:
>
> Or close...
>
> On Wed, 14 Aug 2019 at 18:45,  wrote:
>
> > In a file I have every now and then a record tagged at the
> > beginning, all other lines begin with blanks. I'd like to change
> > the sequence of tagged records with the one directly following it
> > (which is for sure not tagged).
> >
> > I tried with Fanintwo, but failed. I considered a mod of Throttle
> > REXX (based on Dial), another idea with Synchronise, alas even in
> > my imagination it gets rather "gordian/gordic(?)". May be Spec
> > could help with its second reading station.
> >
> > Simpler solutions anyone?
> >
> > Ciao.Mike
> > --
> > www.Ok.de - die kostenlose E-Mail Adresse
> >
>


Re: [CMS-PIPELINES] Punch and deblock

2019-01-25 Thread Michael Harding
Isn't this fun? Thanks John. I wasn't concerned with other stacker
selection as the OP's code used the punch driver. The reminder about substr
is much appreciated, I tend to forget it.

So ever write a collate program for a 2540?  Fun times.

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-3922 | (925) 672-4403 (h)
(925) 323-2070 (m)
/sp


CMSTSO Pipelines Discussion List  wrote on
01/25/2019 04:18:04 PM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 01/25/2019 04:26 PM
> Subject: Re: Punch and deblock
> Sent by: CMSTSO Pipelines Discussion List 
>
> OK, it is/was Friday.
>
> Stacker select x'42' should also be observed in case someone brought a
> real deck of cards to a real card reader.  And remembered how to punch
> and ID card.
>
> And Michael, as of z/VM 6.4 you are allowed to simply |substr 2-*|
> rather than starting all of SPEC.  Sort of like getting on your scooter
> board rather than starting up the combine harvester to go buy a pint of
> milk.
>
> On 1/26/19 00:55, Michael Harding wrote:
> > Forgive me, it's Friday. With a nod in the direction of ancient wisdom,
> > you're mostly right.  In this case though he just need to take a cue
from
> > the proffered code and ignore records without the leading
x'41' (stacker
> > select) then strip that:
> >
> > "reader | strfind x41 | spec 2-* n | deblock cms | > whosyour momma a"
> >
> > --
> > Mike Harding
> > z/VM System Support
> > /sp
> >
> >
> > CMSTSO Pipelines Discussion List  wrote on
> > 01/25/2019 01:50:52 PM:
> >
> >> From: Mike Walter 
> >> To: CMS-PIPELINES@VM.MARIST.EDU
> >> Date: 01/25/2019 01:51 PM
> >> Subject: Re: Punch and deblock
> >> Sent by: CMSTSO Pipelines Discussion List

> >>
> >> Gil,
> >>
> >> The OP showed a sample pipe in which he created a string of text
> >> under 80 characters long, blocked it as F 80, and then used the
> >> PUNCH stage to send it out the virtual punch.  Thus, it was not in
> >> NETDATA format because it was not processed by either the NETDATA
> >> stage, nor SENDFILE command.
> >>
> >> But alerting the OP the existence of the NETDATA stage may open new
> >> avenues for him.  OTOH, he also reported that there are many files
> >> being processed, and NETDATA adds overhead on the sending and
> >> receiving ends.  That said, if the files are longer than LRECL 80,
> >> or are variable length and the variable format must be retained,
> >> then NETDATA/SENDFILE is the proper method.
> >>
> >> Mike Walter
> >> -Retired-
> >>
> >> -Original Message-
> >> From: CMSTSO Pipelines Discussion List 
> >> On Behalf Of Paul Gilmartin
> >> Sent: Friday, January 25, 2019 2:57 PM
> >> To: CMS-PIPELINES@VM.MARIST.EDU
> >> Subject: Re: Punch and deblock
> >>
> >> On 2019-01-25, at 13:40:12, Alain Benvéniste wrote:
> >>> Rob
> >>> I thought to use a pipe reader file to read it back but if it is
> >> not long to show me I would be glad to know how to do that for a
receive.
> >>> Many files are in transit so performance is a plus.
> >>>
> >> Have you looked at:
> >>  https://urldefense.proofpoint.com/v2/url?
> >>
> >
>
u=https-3A__nam02.safelinks.protection.outlook.com_-3Furl-3Dhttps-253A-252F-252Fwww.ibm.com-252Fsupport-252Flibraryserver-5Fos390-252FBOOKS-252FHCSH1C00-252F9.

> >
> >>
> >
>
5-253FDT-253D20090727132928-26amp-3Bdata-3D02-257C01-257C-257Ca6b80f3a949f4694c41d08d68307c074-257C84df9e7fe9f640afb435-257C1-257C0-257C636840466642199203-26amp-3Bsdata-3DyVDmpEdVILc8ohPNW1bVdsHV5p2qaAIb9OCYYpHqN6A-253D-26amp-3Breserved-3D0&d=DwIFAw&c=jf_iaSHvJObTbx-

> >
> >> siA1ZOg&r=jEBtqVYynGR6y_V-
> >> dkwVF1mYKhZoeLn0xfDfGi8GI2A&m=AyiLUAMkCzMF4mRaVsk1mHEIUSBwJ-
> >> wyRFINQbPAVag&s=0S_y2adY48YtHZWWNqqyYsFVd4aQFXPkk6i8X7V9IRc&e=
> >>  9.5 NETDATA Format
> >>
> >>   /* DEBNET REXX -- Deblock a reader file in NETDATA format.
> > */
> >>   'callpipe',
> >>  'reader',/* From reader
> > */
> >>  '| find' '41'x||,/* Only data records
> > */
> >>  '| specs 2-* 1.80',  /* Discard channel command and pad
to 80
> > */
> >>  '| deblock netdata', /* Deblock
> > */
> >>  '| find' 'c0'x||,/* Only data records
> > */
> >>  '| specs 2-* 1', /* Remove control character
> > */
> >>  '| *:'
> >>
> >> -- gil
> >>
>


Re: [CMS-PIPELINES] Punch and deblock

2019-01-25 Thread Michael Harding
Forgive me, it's Friday. With a nod in the direction of ancient wisdom,
you're mostly right.  In this case though he just need to take a cue from
the proffered code and ignore records without the leading x'41' (stacker
select) then strip that:

"reader | strfind x41 | spec 2-* n | deblock cms | > whosyour momma a"

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
01/25/2019 01:50:52 PM:

> From: Mike Walter 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 01/25/2019 01:51 PM
> Subject: Re: Punch and deblock
> Sent by: CMSTSO Pipelines Discussion List 
>
> Gil,
>
> The OP showed a sample pipe in which he created a string of text
> under 80 characters long, blocked it as F 80, and then used the
> PUNCH stage to send it out the virtual punch.  Thus, it was not in
> NETDATA format because it was not processed by either the NETDATA
> stage, nor SENDFILE command.
>
> But alerting the OP the existence of the NETDATA stage may open new
> avenues for him.  OTOH, he also reported that there are many files
> being processed, and NETDATA adds overhead on the sending and
> receiving ends.  That said, if the files are longer than LRECL 80,
> or are variable length and the variable format must be retained,
> then NETDATA/SENDFILE is the proper method.
>
> Mike Walter
> -Retired-
>
> -Original Message-
> From: CMSTSO Pipelines Discussion List 
> On Behalf Of Paul Gilmartin
> Sent: Friday, January 25, 2019 2:57 PM
> To: CMS-PIPELINES@VM.MARIST.EDU
> Subject: Re: Punch and deblock
>
> On 2019-01-25, at 13:40:12, Alain Benvéniste wrote:
> > Rob
> > I thought to use a pipe reader file to read it back but if it is
> not long to show me I would be glad to know how to do that for a receive.
> > Many files are in transit so performance is a plus.
> >
> Have you looked at:
> https://urldefense.proofpoint.com/v2/url?
>
u=https-3A__nam02.safelinks.protection.outlook.com_-3Furl-3Dhttps-253A-252F-252Fwww.ibm.com-252Fsupport-252Flibraryserver-5Fos390-252FBOOKS-252FHCSH1C00-252F9.

>
5-253FDT-253D20090727132928-26amp-3Bdata-3D02-257C01-257C-257Ca6b80f3a949f4694c41d08d68307c074-257C84df9e7fe9f640afb435-257C1-257C0-257C636840466642199203-26amp-3Bsdata-3DyVDmpEdVILc8ohPNW1bVdsHV5p2qaAIb9OCYYpHqN6A-253D-26amp-3Breserved-3D0&d=DwIFAw&c=jf_iaSHvJObTbx-

> siA1ZOg&r=jEBtqVYynGR6y_V-
> dkwVF1mYKhZoeLn0xfDfGi8GI2A&m=AyiLUAMkCzMF4mRaVsk1mHEIUSBwJ-
> wyRFINQbPAVag&s=0S_y2adY48YtHZWWNqqyYsFVd4aQFXPkk6i8X7V9IRc&e=
> 9.5 NETDATA Format
>
>  /* DEBNET REXX -- Deblock a reader file in NETDATA format.
*/
>  'callpipe',
> 'reader',/* From reader
*/
> '| find' '41'x||,/* Only data records
*/
> '| specs 2-* 1.80',  /* Discard channel command and pad to 80
*/
> '| deblock netdata', /* Deblock
*/
> '| find' 'c0'x||,/* Only data records
*/
> '| specs 2-* 1', /* Remove control character
*/
> '| *:'
>
> -- gil
>


Re: [CMS-PIPELINES] SPECS IF ... comparing strings

2018-12-17 Thread Michael Harding
Easy, use a specs variable:
...
'|Specs a: w -1 . . if a=="stuff" then ... else ... endif

The last I knew, double-quotes were the only acceptable delineator for this
construct but that may have changed.
--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
12/17/2018 12:07:28 PM:

> From: Donald Russell 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 12/17/2018 12:09 PM
> Subject: SPECS IF ... comparing strings
> Sent by: CMSTSO Pipelines Discussion List 
>
> I'm using structured data with specs to build a record, and the last word
> of the input record influences part of the value..
>
> Rather than
>  IF1: IF PICK W-1 == /stuff/
>
> SPECS ...
>
> IF1:
>
> SPECS ...
>
> IF1:
>
> Can the SPECS IF clause compare strings, so I can do something like...
>
> SPECS ... IF word(record(),-1) == /stuff/ THEN ... ENDIF
> (The above got a syntax error)
>
> That avoids duplicating things if the two SPECS stage when using the
> IF/THEN/ELSE with PICK.
>
> Thanks,
> Don
>


Re: [CMS-PIPELINES] Selecting multiple record chunks

2018-03-02 Thread Michael Harding
Simple case of "sipping" pipeline:

'PIPE (End ?)',
'<' infile,
'|pck:rexx *.1:',
'|Cons',
'?Literal /* */ Signal On error;',
'Do forever; "Peekto";',   /* test if any input */
'"CallPipe *:||FromTarget Pick 5.2 == /99/ || take 4|| *:";',
'End; Error: Exit Rc*(Rc<>12)',
'|pck:'

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-3922 | (925) 672-4403 (h)
(925) 323-2070 (m)
/sp


CMSTSO Pipelines Discussion List  wrote on
03/02/2018 09:31:01 AM:

> From: "Stanislawski, Shawn (National VM Capability)" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 03/02/2018 09:32 AM
> Subject: Selecting multiple record chunks
> Sent by: CMSTSO Pipelines Discussion List 
>
> I've got some data, within it reside multiple record chunks that I want.
> The desired record chunks are randomly spaced within the data.  The
> desired record chunks are composed of 4 consecutive records.
> The record chunks all start with records whose column 5 & 6 contain
> the characters "99", and then just include the next 3 records (which
> may or may not contain "99" at column 5 & 6).
> Outside of the desired record chunks no other records contain
> characters "99" in column 5 & 6.
> The four records of each record chunk are consecutive in the data,
> but have no common elements or other relation.  And the fifth record
> could be anything: there's no dedicated end string (even within the
> 4 records themselves).
>
> I've included a sampling of data below.
> Records 3, 10, 18 contain "99" at column 5 & 6.
> So the desired output would contain only records 3,4,5,6,10,11,12,
> 13,18,19,20,21
>
> Any ideas?
>
>
> 4L3XEBFVWYR6
> 5O1SLFG7AILX
> 4BW699ETK82T
> S9SK9DIER6L5
> G3AHUKPA4H3I
> Q8ZLYL8G46JY
> COB8GJK1AE5N
> 78MKNQJ8MA6S
> 917JZQ33CXOI
> OQN699MQ60GQ
> Z8VOSOZH6V7L
> VC9V78SK49YS
> L0PI3TLT7PGC
> GFI4QQB1OPA6
> YUBSPLB73SFG
> O7NNK3B20GJD
> 3YPU0MCNSMZN
> R4C899NNU9UB
> FIZK74USTG8F
> OF88HQGAOL3S
> I4O29VT3BMG6
> HPXNGMQQK01G
> CUBL7RY00CIQ
> OBR4YA3Y9GF8
> D28H3IA7PKAX
>
>
> --Shawn S.


Re: [CMS-PIPELINES] getting the RC from third party commands

2018-01-11 Thread Michael Harding
No, the command and cms stages are documented to write all command output
before writing the return code to the secondary stream, which is easily
verified.
The stall occurs because command was stuck writing the return code before
it posted eof on its primary. A simple elastic stage on the second stream
takes care of that.


--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-3922 | (925) 672-4403 (h)
(925) 323-2070 (m)
/sp


CMSTSO Pipelines Discussion List  wrote on
01/11/2018 01:33:54 PM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 01/11/2018 01:33 PM
> Subject: Re: getting the RC from third party commands
> Sent by: CMSTSO Pipelines Discussion List 
>
> On 11 January 2018 at 20:29, Miguel Soltero Diaz  wrote:
>
>
> > Most of the code is REXX. I thought we could use PIPES to do the work.
> >
>
> Yes, you could. I most certainly would. Maybe a bit ambitious as your
first
> real project with CMS Pipelines.
>
> What the trivial examples did not show you is that "command" takes a
stream
> of commands to issue. That makes sense when you generate the commands
from
> another source.
>
> For each command issued, the return code is written to the secondary
> output, then the command response is written to the primary output. The
> reason for your pipeline stall is that the "fanin" expects to read
primary
> input first, then secondary input. If you really just wanted to merge the
> two, you could "faninany" (and get the return code first) or you "buffer"
> the command response and put the return code after it (but that only
makes
> sense when you just issue one command).
>
> What I would probably do is to use the return code of the VMSECURE
command
> to track which commands failed, so that you can review them, or correct
> them, or whatever makes sense. I've done things like that when running
> commands on a group of Linux guests and sometimes those things would fail
> for unexpected reasons to be explored.
>
> Sir Rob the Plumber
>


Re: [CMS-PIPELINES] getting the RC from third party commands

2018-01-10 Thread Michael Harding
Why not just run the VMSECURE module from the COMMAND stage? It knows how
to communicate with the VMSECURE machine, displays the messages and sets
the return code, both of which COMMAND will capture.

For example...
'pipe (stagesep ! endchar ?)',
   '  Var vmcmd',  /* assumed to be "vmsedure" */
   '! cc:Command',
   '! rr:Fanin',
   '! >> GTPRIV REPT A',
   '? cc:',   /* return code comes here */
   '! Specs /Return code was/ 4 w1 nw',
   '! rr:'/* append to output */

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-3922 | (925) 672-4403 (h)
(925) 323-2070 (m)
/sp


CMSTSO Pipelines Discussion List  wrote on
01/10/2018 02:28:33 PM:

> From: Miguel Soltero Diaz 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 01/10/2018 02:29 PM
> Subject: getting the RC from third party commands
> Sent by: CMSTSO Pipelines Discussion List 
>
> hello guys,
> I am trying to execute a VMSECURE command and capture the return
> code of that command. So far, I am able to get the results from the
> command but not the rc.
> Is there a way to capture the rc from that command?
> is this something I should be talking to CA instead?
>
> This is the way I am executing the command using pipes.
> 'pipe (stagesep ! endchar ?)',
>  '! VAR VMCMD !STARMSG *MSGALL',
>  '! >> GTPRIV REPT A',
>
> When the command is executed I get
> whatever results from the command and ...
> Ready(00024); T=0.01/0.01 14:18:19
>
>
> Ready(00024) is what I am after... and so far unable to get to it.
>
> is there a way to get it?
>
> Thx
>


Re: [CMS-PIPELINES] GLOBALV

2017-12-21 Thread Michael Harding
Or...
'PIPE command GLOBALV SELECT $$RDRLIS LIST | ... '  and locate or pick the
item(s) of interest.

--
Mike Harding
/sp


CMSTSO Pipelines Discussion List  wrote on
12/21/2017 07:31:37 AM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 12/21/2017 07:31 AM
> Subject: Re: GLOBALV
> Sent by: CMSTSO Pipelines Discussion List 
>
> Steve,
>
> Not really. CMS does not provide a native interface for CMS Pipelines to
> exploit.
>
> You can do things with "command" like this:
>   'PIPE command GLOBALV SELECT $$RDRLIS STACK RDATETYP | append stack
| ...'
>
> If you write a REXX filter, the value() function may be useful to do what
> you need.
>
> Rob
>
>
> On 21 December 2017 at 16:24, Gentry, Steve <
> steve.gen...@westernsouthernlife.com> wrote:
>
> > Hi.  Is it possible to issue the GLOBALV   command from pipes?  Or is
> > there a STAGE to retrieve the info?
> > I've tried a number of combination of commands with no luck.  Those
> > include  "| CMS GLOBALV . . . ." ,  "| CP GLOBALV . . . ." ,  "|
COMMAND
> > GLOBALV . . . . "  and a couple of things with SPEC.
> > I could just read the file in a pipe and get what I want but prefer not
to.
> > Thanks,
> > Steve
> >
>


Re: [CMS-PIPELINES] Variable field selection

2017-05-03 Thread Michael Harding
Agree with Alan.  Any unspecified argument is "OMITTED".  Note that z/VM
Rexx, OpenObject Rexx and Regina Rexx all specify Arg() as returning the
number of the last EXPLICIT argument.  That doesn't mean your
subroutine/function can't look for more as long as it can handle their
being null.  Or in your example you could have kept going beyond the 4th
argument but what's the point, you know they aren't specified.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
05/03/2017 01:25:01 PM:

> From: Alan Altmark/Endicott/IBM@IBMUS
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 05/03/2017 01:25 PM
> Subject: Re: Variable field selection
> Sent by: CMSTSO Pipelines Discussion List 
>
> > But, I can't provide an "OMITTED" final argument, no matter how
> > many commas or blank lines I supply.
>
> If you mean that REXX doesn't distinguish between a null string and an
> omitted string, that's true.  My programs all use the null string in an
> argument to indicate omission, since that what you get with the ", ,"
> idiom.  So my program can decide it wants the "default" behavior at
> runtime without having to have two different CALLs or function
> invocations.
>
> I like it that way.  :-)
>
> Alan Altmark
>
> Senior Managing z/VM and Linux Consultant
> Lab Services System z Delivery Practice
> IBM Systems & Technology Group
> ibm.com/systems/services/labservices
> office: 607.429.3323
> mobile; 607.321.7556
> alan_altm...@us.ibm.com
> IBM Endicott
>


Re: [CMS-PIPELINES] Variable field selection

2017-05-03 Thread Michael Harding
Too sly, but inventive!

I personally like to code "parse value function() with ."; safe with or
without a returned value.
--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
05/03/2017 11:39:04 AM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 05/03/2017 11:41 AM
> Subject: Re: Variable field selection
> Sent by: CMSTSO Pipelines Discussion List 
>
> On 3 May 2017, 14:30:18, Alan Altmark wrote:
>
> > I have pretty much abandoned CALL in CMS in favor of function calls
with
> > null return values.  The REXX interface to CMS (REXEXT macro)
suppresses
> > any null command, so I can get more creative in the way I call
functions
> > without resorting to syntax crutches like the ones above.  It ensures
that
> > there is never ambiguity in the purpose of a trailing comma.
>
> Or NUCXLOAD a module as 0, 28, and whatever good return codes you get ;-)
>
> Rob
>


[CMS-PIPELINES] Variable field selection

2017-05-02 Thread Michael Harding
I thought I remembered an idiom in specs for specifying field selections
when the field separation character wasn't known before hand, but now can't
find or seem able to reinvent it.
The equivalent of the ability in Rexx to assign a value to a variable and
use that variable as a separator later in the same parse operation.
   Such as  "parse var input 1 fs +1 1 (fs) varname (fs) varvalue" for
example to pick apart the output of a rexxvars toload stage.
Am I dreaming?

--
Mike Harding
z/VM System Support
/sp


Re: [CMS-PIPELINES] Pipethink and filtering. CP QUERY PATHS 0-FFFF

2017-03-24 Thread Michael Harding
Yes, for the result the OP finally stated I agree joincont would be the way
to go, but that was unclear in the original post.  Thus the "'||join
* /;/',   /* process one group here */" in my post to suggest additional
logic could be applied even though yes, that too could in most cases could
follow a simple joincont.
It just got me to wondering though how much could be done in terms of
emulating a sipping rexx stage without resorting to rexx.  Which led to the
poser of why the take last - gate construct  didn't work as I would have
expected.  That's the real reason for my post, not suggesting a solution
for the OP's message.

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-3922 | (925) 672-4403 (h)
(925) 323-2070 (m)
/sp


CMSTSO Pipelines Discussion List  wrote on
03/24/2017 01:09:18 PM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 03/24/2017 01:16 PM
> Subject: Re: Pipethink and filtering. CP QUERY PATHS 0-
> Sent by: CMSTSO Pipelines Discussion List 
>
> > Perfect for a sipping stage I thought when I read the initial post,
before
> > seeing the "pure pipes" preference; then I wondered if an equivalent
could
> > be accomplished with pipcmd.
>
> I am often wrong, but why go all that way to mimic a built-in stage?You
can do
> all that with joincont from what I see.
>
> So I understand we're after showing the original CP response for that
device,
> just have not heard what 'that device' would be. Is it when the
> signs for (LPM)
> don't match (PIM) or when there ar any '-' sings on (LPM), or what?
>
> Sir Rob the Plumber
>


Re: [CMS-PIPELINES] Pipethink and filtering. CP QUERY PATHS 0-FFFF

2017-03-24 Thread Michael Harding
Perfect for a sipping stage I thought when I read the initial post, before
seeing the "pure pipes" preference; then I wondered if an equivalent could
be accomplished with pipcmd.
Attempting -
   Address Command
   'PIPE (end ?) cp Q PATHS E1D8-E1DB',
   '|a:Take last',  /* legend line? */
   '|b:gate',
   '?Literal CallPipe (End ??) *.in.1:',
  '||aa:drop 1',
  '||Strtolabel /Device/',
  '||cc:Faninany',
  '||join * /;/',/* process one group here */
  '||*.out.0:',
  '??aa:',
  '||cc:',
   '|dup *',
   '|b:',
   '|c:pipcmd',
   '|cons',
   '?a:|c:'
produced the expected output then hung, apparently in a loop.  Gate doesn't
seem to be firing.  Placed a Cons stage between the take last and the gate
and sure enough the last (Legend) line doesn't appear.

One could argue that I need to add "strict" to gate, and I did to no avail
as the last record of the cp stage's output still wasn't being passed.
Finally changed the "dup *" to a small number, though still greater than
the expected number of iterations.
   Address Command
   'PIPE (end ?) cp Q PATHS E1D8-E1DB',
   '|a:Take last',  /* legend line? */
   '|cons',
   '|b:gate strict',
   '?Literal CallPipe (End ??) *.in.1:',
  '||aa:drop 1',
  '||Strtolabel /Device/',
  '||cc:Faninany',
  '||join * /;/',   /* process one group here */
  '||StrLit ifempty /past eof/',
  '||*.out.0:',
  '??aa:',
  '||cc:',
   '|dup 7',
   '|b:',
   '|c:pipcmd',
   '|cons',
   '?a:|c:'
   Exit Rc
And I now get the desired 4 lines of output (as there are only 4 devices in
the range used), followed by 4 lines of "past eof" and finally the "Legend"
line.

So why is the take stage holding the last record, when the cp stage
must be at eof?  A copy stage inserted in the last line "?a:|copy|c:" to
ensure the penultimate line was sucked off also didn't help.

What am I missing?
Thanks,
--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 672-3922 | (925) 672-4403 (h)
(925) 323-2070 (m)
/sp


CMSTSO Pipelines Discussion List  wrote on
03/23/2017 02:39:47 PM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 03/23/2017 02:56 PM
> Subject: Re: Pipethink and filtering. CP QUERY PATHS 0-
> Sent by: CMSTSO Pipelines Discussion List 
>
> > Juxtapose - if you have a group of records that aren't easy to
> tell they're associated, make it so they are.
>
> Sure, and lookup :-)
>
> I don't have a picture of your expected output yet. Some generai ideas:
>
> You can group the records per device into a chunk with something like
>  'joincont leading / / x15'
> and still be able to reconstruct the lines.
>
> If you use 'fanout' to have a copy of the original records. Rather than
> identify the good one,s you might be able to identify the bad ones. If
> nothing else you might split the streams by (PIM) etc tags and use a
> 'combine' stage to recognize a mix (e.g. all '-' or '+' stays like that,
> but a mix would result in '>'). If necessary use 'xlate' to pick elegant
> code points for the '+' and '-' signs.
>
> Something I like is to use 'predselect' to throw out or select records
> when you may have more than one trigger. So you'd have 'predselect'
> pass or reject the "chunked" records based on whether the detailed
> analysis gave a reason to reject.
>
> If nothing else, you can certainly write yourself a sipping pipeline in
> REXX and process each chunk on its own.
>
> Sir Rob the Plumber
>


Re: [CMS-PIPELINES] SPEC IF String equality comparison and output including Field identifiers.

2016-12-14 Thread Michael Harding
Also...  older pipes didn't like the use of a named range as the argument
to print.  Changing "print a" to "id a" would work.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
12/14/2016 01:59:42 PM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 12/14/2016 02:33 PM
> Subject: Re: SPEC IF String equality comparison and output including
> Field identifiers.
> Sent by: CMSTSO Pipelines Discussion List 
>
> > The way Ive written a SPEC stage appears to be causing error:
> >
> > FPLSPX1038E Not a decimal number: RANDOM EXEC F 80 40 1 2013-02-06
07:40:30
> > FPLMSG003I ... Issued from stage 5 of pipeline 1
> > FPLMSG001I ... Running "SPEC a: 1-* . SELECT SECOND b: 1-* . IF (a,==b)
TH"
> >
> > Input is paired sets of records (strings via two LISTFILE, already
> fed through a LOOKUP).
> > The intention is that output will be suppressed unless the pair of
> records (strings) are not equal.
>
> The messages suggest that you're using older plumbing that did not do
strings
> in named fields like that. But apart from that, this is probably not what
you
> want to do. The 'second reading' in spec makes it process each record
twice,
> not process records pairwise.
>
> There is 'unique pairwise' that might help you out. But if you're
comparing
> the records pairwise like that, the more obvious approch is to put the
two
> records side by side and use 'pick' on the two ranges.
>
>pad 100 | join | pick 21.80  /== 121.80
>
> If you know the length of the records, you can tell where the ranges are.
I
> was a bit lazy and made them 100 wide so the numbers were easier to
compute.
>
> PS I think this is the last example from my series 'Showing Off with
Lookup'
> that I had in my presentation in Munch this spring. I notice it has the
same
> trick with the 'pad 100' ;-)
>
> /* NEWFILES EXEC On both, show newer */
> arg fn ft fm1 fm2 . ; if fm2 = '' then exit 24
> address command
> 'PIPE (end \ name NEWFILES.EXEC:7)',
>   '\ command LISTFILE' fn ft fm1 '( NOH ISO',
>   '| x: lookup w1.2 detail master',
>   '| pad 100',
>   '| join',
>   '| pick 57.19 >> 157.19',
>   '| chop 20',/* Just fn ft fm */
>   '| cons',
>   '\ command LISTFILE' fn ft fm2 '( NOH ISO',
>   '| x:',
> exit rc
>
> And I owe you some neat examples with 'select second'
>
> Sir Rob the Plumber
>


Re: [CMS-PIPELINES] Capture rexx output with both CP and CMS commands

2016-11-28 Thread Michael Harding
This might supply a good starting point:

/*
**
*/
Address Command
Parse value Diag(8,'QUERY SET') with 1 . 'VMCONIO' vms . ',' 1 . 'CPCONIO'
pms . ','
nl = '15'x
Parse value Diag(8,'SET VMCONIO IUCV'nl'SET CPCONIO IUCV') with .
Parse arg stuffs
'PIPE var stuffs|starmsg *MSGALL|spec 17-* n|stem dumb.'
Parse value Diag(8,'SET VMCONIO' vms nl'SET CPCONIO' pms) with .
Do i=1 to dumb.0
   Say i dumb.i
   End
Exit 0

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
11/28/2016 12:32:58 PM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 11/28/2016 12:33 PM
> Subject: Re: Capture rexx output with both CP and CMS commands
> Sent by: CMSTSO Pipelines Discussion List 
>
> Alan, CMS does not trap commands that are forwarded to CP by the default
> setting IMPCP on; nor explicitly by the CP command of CMS.
>
> I'd say SPOOL the console.  Or perhaps read the manual.
>
> It is true that
>
>PIPE literal  | starmsg | ...
>
> will do as requested, but I'm sure something will go awry for this
> unsuspecting newbee.
>
> On 11/28/2016 09:13 PM, Alan Altmark wrote:
> > On Monday, 11/28/2016 at 07:06 GMT, Offer Baruch

> > wrote:
> >> Hello everyone,
> >>
> >> I am new to the list and need some assistance...
> >>
> >> I am trying to capture the output of a Rexx exec. the Rexx contains
both
> >> CMS and CP commands...
> >> I would like to capture this output into a stem variable...
> >>
> >> something like:
> >> PIPE  | STEM output.
> >>
> >> At the moment i feel like i am in a dead lock...
> >> I am unable to use the PIPE CMS command to run my rexx as the CP
command
> >> output will not be captured...
> >> I am unable to use the PIPE REXX command as my rexx is not a stage and
> > uses
> >> "say" along with CP and CMS commands... it is not using 'OUTPUT'...
> > causing
> >> the output to hit the terminal and not the next stage of the STEM.
> >>
> >> I am aware that i can use the PIPE CMS and workaround the issue by
using
> >> the following inside my Rexx for CP commands:
> >> PIPE CP  | STEM var.
> >> and then printing the content of var. using say...
> >> the problem is i don't control the Rexx and i am trying to avoid
forcing
> > my
> >> users to rewrite their scripts...
> >>
> >> All i am asking is to be able to trap the output of any Rexx exec no
> > matter
> >> what commands it uses...
> >>
> >> Say in TSO/Rexx you have the OUTTRAP function to help you do that...
> >>
> >> any ideas anyone? am i missing something?
> >
> > Start with
> >   PIPE CMS  | STEM var.
> >
> > That will let you trap the output of any CMS or synchronous CP commands
> > issued by their program.  You can then massage that output to interpret
it
> > or reformat it.  But much depends on the specific CP commands they
issue
> > and how they issue them.  If they issue DIAGNOSE 8 themselves, you may
not
> > be able to trap it without using SCIF and PIPE STARMSG.  But again, it
> > depends on how they dispose of the output from DIAGNOSE 8.
> >
> > Asynchronous responses from CP must be trapped via STARMSG.
> >
> > Alan Altmark
> >
> > Senior Managing z/VM and Linux Consultant
> > Lab Services System z Delivery Practice
> > IBM Systems & Technology Group
> > ibm.com/systems/services/labservices
> > office: 607.429.3323
> > mobile; 607.321.7556
> > alan_altm...@us.ibm.com
> > IBM Endicott
> >
>


[CMS-PIPELINES] Archives search?

2016-10-24 Thread Michael Harding
Didn't Harry (Williams) have an archives search set up at one time?  I
can't seem to find it now.
Thanks,
--
Mike Harding
z/VM System Support
/sp


Re: [CMS-PIPELINES] Not-always-directly-sequential record references in PIPEs

2016-09-22 Thread Michael Harding
You could code some complicated conditionals and use counters in Specs, but
much simpler: look into JUXTAPOSE.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
09/22/2016 07:47:03 AM:

> From: "Stanislawski, Shawn (National VM Capability)" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 09/22/2016 07:47 AM
> Subject: Not-always-directly-sequential record references in PIPEs
> Sent by: CMSTSO Pipelines Discussion List 
>
> I'm sure this has to be a very easy question, but unfortunately I'm
> still struggling with it.
>
> How can I turn this file (Original) :
> "
>
> *VOLUME: AA1A11  TYPE: 3390 UTILIZATION: 99%
>
> *FREE* 2  54 55 *FREE* POOLA
>
> *FREE* 2  194195*FREE* POOLA
>
> *FREE* 1  614614*FREE* POOLA
>
> *VOLUME: BB2B22  TYPE: 3390 UTILIZATION: 73%
>
> *FREE* 5001  500*FREE* POOLB
>
> *FREE* 1651040   1204   *FREE* POOLB
>
> *FREE* 5  1706   1710   *FREE* POOLB
> "
>
> Into this console output (Result) :
> "
>
> AA1A11 3390   2  54 55POOLA
>
> AA1A11 3390   2  194195   POOLA
>
> AA1A11 3390   1  614614   POOLA
>
> BB2B22 3390   5001  500   POOLB
>
> BB2B22 3390   1651040   1204  POOLB
>
> BB2B22 3390   5  1706   1710  POOLB
> "
>
> using PIPEs?
>
>
> I know I can use SPECS to rearrange the data in a single record, so
> getting Result columns 3-6 is easy.
>
> The problem I cannot seem to figure out is how to:
>
> 1.   take the two columns of data from the "*VOLUME:" record then
>
> 2.   prepend that to the front of each "*FREE*" record ,
>
> 3.   and when next "*VOLUME:" record encountered then use that
> new data to prepend to the next set of records.
>
>
> I was trying:
> "
>
> 'PIPE (endchar ?) < SOMEFILE MAP A'  ,
>
>   '| A: FIND *VOLUME'   ,
>
>'|SPECS W2 1 W4 NW'   ,
>
>'|VAR VOLSER1 TRACK'  ,
>
> '?A:|COPY'   ,
>
>'|COPY'   ,
>
>'|SPECS /'VOLSER1'/ 1 1-* nw' ,
>
>   '|CONSOLE'
> "
> ...but it looks like REXX Variable "VOLSER1" is not getting set -
> instead the PIPE literally prepends the string "VOLSER1" to the
> front of the records.
>
>
> Any ideas?
>
>
> --Shawn S.
>


Re: [CMS-PIPELINES] Incorrect Handling of Negative Numbers With PICK?

2016-08-23 Thread Michael Harding
Wrong, that should be doing a numeric compare.  Look it up.
A comparison operator of <<= would be for a string compare.  "<=" asks for
numeric comparison.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
08/23/2016 01:58:27 PM:

> From: Ronald van der Laan 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 08/23/2016 01:59 PM
> Subject: Re: Incorrect Handling of Negative Numbers With PICK?
> Sent by: CMSTSO Pipelines Discussion List 
>
> Michael,
>
> You're doing string compares, so "-0.." is less than "-1".
> You'll also find that "-200.000" will not pass your filter...
> Try  ... | pick substr 1 of w2 = /-/ and substr 2-* of w2 >>=
> /0001.00/ | ...
>
> Op dinsdag 23 augustus 2016 heeft Michael Marrer 
> het volgende geschreven:
>
> > This would seem to be basically working, as I do get the numbers less
> > than negative 1 in the output file:
> >
> > pipe '  (end ?) < ' filename filetype filemode,
> >  '| pick w2  <= /-1/ ',
> >  '| > ' filename ' WORDOVER ' filemode,
> >  ' '
> >
> > The problem is that I get ALL negative numbers, not just those less
> > than negative 1.  For example, these get selected as well:
> >
> > -
> >
> > -.007800
> >
> > So does anyone have any idea what is going wrong?
> >
> > I know I can also accomplish what I want by defining the word with a
> > variable in a SPECs stage and doing an IF/THEN operation, but as I
> > will be doing other tests on that word as well as other words in the
> > data file, it will get a little convoluted.
> >
> > I believe this represents the level of Pipes we are using:
> >
> > 11 Rev 0C Mod 0002
> > 110C0002
> >
>
>
> --
> Ronald van der Laan
>


Re: [CMS-PIPELINES] Speaking of SPECS NUMBER

2016-06-28 Thread Michael Harding
pipe literal *|dup 8|spec if #0=='' then set #0:=-5 else set #0+=1 endif
print #0 n|Cons
 -5
 -4
 -3
 -2
 -1
  0
  1
  2
  3
Ready; T=0.01/0.01 13:26:02

--
Mike Harding
z/VM System Support

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 06/28/2016 01:01 PM
> Subject: Re: Speaking of SPECS NUMBER
> Sent by: CMSTSO Pipelines Discussion List 
>
> #0 will never become positive.  Is that what you wanted?


Re: [CMS-PIPELINES] the STACK stage

2016-06-24 Thread Michael Harding
Too complicated if he only wants the first stacked item.  The VAR stage,
without the TRACKING option assigns its first input to the variable then
shorts.  So the take 1 is unnecessary, and one possible solution is simply:
PIPE Stack',
'|Var expdt',
'|Hole'
would fit the bill.

Or to build on Paul's question:
'PIPE (End ?) Stack',
'|a:Take 1',
'|Var expdt',
'?a:|Hole'
--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
06/24/2016 09:21:03 AM:

> From: Mike Walter 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 06/24/2016 09:23 AM
> Subject: Re: the STACK stage
> Sent by: CMSTSO Pipelines Discussion List 
>
> Steve,
> If you expect three stacked records, are they all the same format,
> where 33.8 is an expdt?  If so, then do you want to do with each of
> those expdts?
> Changing your '| VAR expdt' stage to something like '| STEM expdts.'
> with three stavked input records containing expdts in 33.8 would
> create rexx stem variables:
> expdts.0=0expdts.1='xx/xx/xx'expdts.2='xx/xx/xx'expdts.3='xx/xx/
> xx'Where 'xx/xx/xx' is the expdt of each record in whatever format
> was stacked.
> Mike Walter
> Sent from my Verizon, Samsung Galaxy smartphone
> 
>  Original message
> From: "Gentry, Steve"
>  Date: 6/24/16  12:
> 06 PM  (GMT-05:00) To: CMS-PIPELINES@VM.MARIST.EDU  div>Subject: Re: the STACK stage 
> 
> Possibly,(and I thought of that) but I'm not experienced enough to
> know how to code that.  This was something I had to get done very
> quickly.  I may go revisit.
> Steve
>
> -Original Message-
> From: CMSTSO Pipelines Discussion List
[mailto:CMS-PIPELINES@VM.MARIST.EDU
> ] On Behalf Of Paul Gilmartin
> Sent: Friday, June 24, 2016 11:59 AM
> To: CMS-PIPELINES@VM.MARIST.EDU
> Subject: Re: the STACK stage
>
> On 2016-06-24, at 08:19, Gentry, Steve wrote:
>
> > I'm not getting the results I'd expect when STACK is the first in
> a pipeline.   What I thought would happen is the entire STACK is
> read into the stream and then proceed onto the next stage.  This is
> not happening.  Here is my code:
> > 'PIPE stack' ,
> >   '| take 1' ,
> >   '| spec 33.8 1' ,
> >   '| var EXPDT'
> >
> Since TAKE shorts the remainder of its input to its secondary output
> stream, would it work to connect that secondary stream to HOLE?
>
> > I will have at least three lines in the stack.  These three lines
> are created by another   command that uses the " STACK FIFO" (w/o the
quotes).
> >
> I've hardly mastered connectors.  I'd first try STACK LIFO then TAKE LAST
1.
>
> -- gil
>


Re: [CMS-PIPELINES] Split a file into multiple files based on a string in the data

2015-10-06 Thread Michael Harding
If your totarget immediately follows the fromtarget, they're triggering on
the same record.  You need to bypass feeding the first record to the
totarget.

Simplest case, you don't want keep the separator records:

...
'|fromtarget locate /file/',
'|drop 1',
'|totarget locate /file/",
...

If you want to keep the separator,

...
'|fromtarget locate /file/',
'|a:take 1',
'|b:Fanin',
...
'?a:|totarget locate /file/',
'|b:'
...

For recursion you'd want a sipping rexx stage:

Signal on error
i = 0
Do forever
  'Peekto'  /* check another record */
  i = i + 1
  'Callpipe *:|Fromtarget locate /file/|a:take 1|b:fanin|> file'i 'data
a?a:|totarget locate /file/|b:'
  End
--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
10/06/2015 10:16:57 AM:

> From: Rick Barlow 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 10/06/2015 10:17 AM
> Subject: Split a file into multiple files based on a string in the data
> Sent by: CMSTSO Pipelines Discussion List 
>
> I want to take a single file and split it into multiple files based on a
> string in the data. I don't know how many parts are in the original file.
> The string is not necessarily at the beginning of a record.
> Example:
>
> This is file 1
> rec1
> rec2
> This is the beginning of file 2
> f2rec1
> f2rec2
> f2rec3
> f2rec3
> This is file 3
> f3rec1
> f3rec2
> I want to end up with 3 files. I know I can use fromtarget locate /file/.
I
> haven't been able to find a way to go totarget locate /file/ because it
> does not select anything. I also haven't been able to come up with a way
to
> do this recursively. I know that I am probably overlooking something
> relatively obvious. Any suggestions would be appreciated.
>
> Rick Barlow
> Nationwide Insurance
>


[CMS-PIPELINES]

2015-07-31 Thread Michael Harding
CMSTSO Pipelines Discussion List  wrote on
07/31/2015 03:21:22 AM:

> From: John Hartmann 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/31/2015 02:21 AM
> Subject: Re:
> Sent by: CMSTSO Pipelines Discussion List 
>
> pipe < pipeline module |digest sha1 | spec 1-8 c2x 1 | cons
> 39C619B28DB50D02
>
pipe < pipeline module a |digest sha1 | spec 1-8 c2x 1 | cons
39C619B28DB50D02
Ready; T=0.01/0.01 08:37:18
pipe < pipeline module b |digest sha1 | spec 1-8 c2x 1 | cons
B3A05504BCD13361
Ready; T=0.01/0.01 08:37:23
la pipeline module ab
FILENAME FILETYPE FM FORMAT LRECL   RECS BLOCKS   DATE TIME
LABEL
PIPELINE MODULE   A1 V  65535 21292  7/30/15  9:26:57
MBH191
PIPELINE MODULE   B1 V  65535 21295  1/13/15  1:57:53
MBHCOM
Ready; T=0.01/0.01 08:38:05

--
Mike Harding
z/VM System Support
/sp


Re: [CMS-PIPELINES] 1.1.12/000C is available for download.

2015-07-30 Thread Michael Harding
CMSTSO Pipelines Discussion List  wrote on
07/30/2015 08:33:51 AM:

> From: John Hartmann 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/30/2015 07:34 AM
> Subject: 1.1.12/000C is available for download.
> Sent by: CMSTSO Pipelines Discussion List 
>
> Fix problems with SPEC counters that contain strings.  Implement the ||=
> operator.
>
> Happy plumbing,
>
>j.
I was able to download from the web, but new files don't seem to have made
it to ftp directory.  And yes, my previously failing pipeline now works.
Thanks!

--
Mike Harding
z/VM System Support
/sp


Re: [CMS-PIPELINES] Capturing output from a pipe

2015-07-20 Thread Michael Harding
CMSTSO Pipelines Discussion List  wrote on
07/20/2015 11:30:18 AM:

> From: "Gentry, Steve" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/20/2015 11:30 AM
> Subject: Re: Capturing output from a pipe
> Sent by: CMSTSO Pipelines Discussion List 
>
> Correct, sort of.  I want to programmatically capture those
> messages.  I just did a cut-n-paste from the console log to the
> email to show as an example.

Take a look then at Kris Buelens' MAILIT package on the download page. Once
you capture you error messages in a stem or file using previously-described
methods, MAILIT makes it easy then to post (as in mail) them.
A simplified (untested) shell exec would look something like:

Address Command
'PIPE Command EXEC |stem errors.'
If errors.0>0 then 'EXEC MAILIT to  subject(errors from)
stem errors.',
   'preface(Here are the errors reported during the execution of ' ||
'1515'x || ')'
--
Mike Harding
z/VM System Support
/sp


Re: [CMS-PIPELINES] Capturing output from a pipe

2015-07-20 Thread Michael Harding
CMSTSO Pipelines Discussion List  wrote on
07/20/2015 11:14:32 AM:

> From: Paul Gilmartin 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/20/2015 11:14 AM
> Subject: Re: Capturing output from a pipe
> Sent by: CMSTSO Pipelines Discussion List 
>
> On 2015-07-20 12:04, Gentry, Steve wrote:
> > I thought of both of these:
> > SPOOL, couldn't figure out how to do this dynamically.  I'd only
> want to do this before this pipe starts and return it to normal
> after the pipe is done.
> >
> If the SQL pipe is embedded in an EXEC, you should be able to
> SPOOL START before the PIPE SQL command and SPOOL STOP CLOSE after.
> But this may interfere with existing spooling for other purposes.
>
> > HYPER:  I didn't know you could do this.
> >
> Sorry; I was inventing jargon.  If the SQL pipe is embedded in
> an EXEC (as above), you should be able to PIPE CMD EXEC SQLPIPE |
> stem.
>
> (I am not a master plumber.)
>
> -- gil
>
Okay, I'm missing something but the original post said you wanted to
capture the messages and include in an email, which you'd already
accomplished in the act of posting the question.

--
Mike Harding
z/VM System Support
/sp


Re: [CMS-PIPELINES] Assertion failure?

2015-07-16 Thread Michael Harding
Slight amendment: upon further playing, it appears one can concatenate to a
counter as much as one wants, as long as one doesn't try to reset it to
null, then start concatenating to it again.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
07/16/2015 12:33:07 PM:

> From: Michael Harding/Oakland/IBM@IBMUS
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/16/2015 12:33 PM
> Subject: Re: Assertion failure?
> Sent by: CMSTSO Pipelines Discussion List 
>
> Poking around in the dump a bit, I figured out I was probably exceeding a
> counter's (#5) string capacity.  Coded around that and program now works
> but is more complicated.
>
> --
> "Every palace and every work of art is only dust as yet unrealized, and
> time is the patient wind that will wither it away." -- Dean Koontz, "The
> Face"
>
> Mike Harding
> z/VM System Support
> /sp
>
>
> CMSTSO Pipelines Discussion List  wrote on
> 07/16/2015 10:18:05 AM:
>
> > From: Michael Harding/Oakland/IBM@IBMUS
> > To: CMS-PIPELINES@VM.MARIST.EDU
> > Date: 07/16/2015 10:18 AM
> > Subject: Assertion failure?
> > Sent by: CMSTSO Pipelines Discussion List 
> >
> > Any ideas?
> > With latest plastic pipes,
> >
> > PIPINX409E Assert failure 01C4 at 01EF7632.
> > PIPINX411I ... In FPLSPSRL; offset 08DA in FPLSPS 11/08/14 13.17.
> > PIPINX412I ... GPR0: 000A 01F5738C 07C0 .
> > PIPINX412I ... GPR4: 01F5A7C0 000C  01F5738C.
> > PIPINX412I ... GPR8: 01F5A000 01F456F8 01F5A000 01F56C60.
> > PIPINX412I ... GPRC: 81EF7604 01F57858 81EF7614 C6998585.
> > PIPINX413I ... Store 01EF7628: BFFF4000 4720C030 01C4 5BF0C8BC
> > 47D0C04A.
> > PIPINX1198I Stage is active.
> > PIPMSG004I ... Issued from stage 5 of pipeline 1 name "siGh".
> > PIPMSG001I ... Running "Spec printonly a select second a: 1.3 . b: w2 .
> > c:".
> > DMSABE141T Operation exception occurred at 81EF7632 in routine PIPE
> >
> > The stage in question:
> >
> > '|Spec printonly a select second',
> >'a: 1.3 . b: w2 . c: w3 .',
> >'set (#0:=a*5;#1:=#0+4;#3+=1;#4+=b;#5:=#5" "c)',
> >'break a',
> >'print #0 pic v n /-/ n print #1 pic v n',
> >'print #3 pic 9v 19.5 right',
> >'print #4/#3 pic zzz9.v99 25',
> >'print #5 35',
> >'set (#3:=0;#4:=0;#5:="")',
> >
> > It has taken the break once and produced the expected output.  I have a
> > dump, haven't yet analyzed it.
> > Thanks for any pointers
> > --
> > "Every palace and every work of art is only dust as yet unrealized, and
> > time is the patient wind that will wither it away." -- Dean Koontz,
"The
> > Face"
> >
> > Mike Harding
> > z/VM System Support
> >
> > /sp
> >
>


Re: [CMS-PIPELINES] Assertion failure?

2015-07-16 Thread Michael Harding
Poking around in the dump a bit, I figured out I was probably exceeding a
counter's (#5) string capacity.  Coded around that and program now works
but is more complicated.

--
"Every palace and every work of art is only dust as yet unrealized, and
time is the patient wind that will wither it away." -- Dean Koontz, "The
Face"

Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
07/16/2015 10:18:05 AM:

> From: Michael Harding/Oakland/IBM@IBMUS
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/16/2015 10:18 AM
> Subject: Assertion failure?
> Sent by: CMSTSO Pipelines Discussion List 
>
> Any ideas?
> With latest plastic pipes,
>
> PIPINX409E Assert failure 01C4 at 01EF7632.
> PIPINX411I ... In FPLSPSRL; offset 08DA in FPLSPS 11/08/14 13.17.
> PIPINX412I ... GPR0: 000A 01F5738C 07C0 .
> PIPINX412I ... GPR4: 01F5A7C0 000C  01F5738C.
> PIPINX412I ... GPR8: 01F5A000 01F456F8 01F5A000 01F56C60.
> PIPINX412I ... GPRC: 81EF7604 01F57858 81EF7614 C6998585.
> PIPINX413I ... Store 01EF7628: BFFF4000 4720C030 01C4 5BF0C8BC
> 47D0C04A.
> PIPINX1198I Stage is active.
> PIPMSG004I ... Issued from stage 5 of pipeline 1 name "siGh".
> PIPMSG001I ... Running "Spec printonly a select second a: 1.3 . b: w2 .
> c:".
> DMSABE141T Operation exception occurred at 81EF7632 in routine PIPE
>
> The stage in question:
>
> '|Spec printonly a select second',
>'a: 1.3 . b: w2 . c: w3 .',
>'set (#0:=a*5;#1:=#0+4;#3+=1;#4+=b;#5:=#5" "c)',
>'break a',
>'print #0 pic v n /-/ n print #1 pic v n',
>'print #3 pic 9v 19.5 right',
>'print #4/#3 pic zzz9.v99 25',
>'print #5 35',
>'set (#3:=0;#4:=0;#5:="")',
>
> It has taken the break once and produced the expected output.  I have a
> dump, haven't yet analyzed it.
> Thanks for any pointers
> --
> "Every palace and every work of art is only dust as yet unrealized, and
> time is the patient wind that will wither it away." -- Dean Koontz, "The
> Face"
>
> Mike Harding
> z/VM System Support
>
> /sp
>


[CMS-PIPELINES] Assertion failure?

2015-07-16 Thread Michael Harding
Any ideas?
With latest plastic pipes,

PIPINX409E Assert failure 01C4 at 01EF7632.
PIPINX411I ... In FPLSPSRL; offset 08DA in FPLSPS 11/08/14 13.17.
PIPINX412I ... GPR0: 000A 01F5738C 07C0 .
PIPINX412I ... GPR4: 01F5A7C0 000C  01F5738C.
PIPINX412I ... GPR8: 01F5A000 01F456F8 01F5A000 01F56C60.
PIPINX412I ... GPRC: 81EF7604 01F57858 81EF7614 C6998585.
PIPINX413I ... Store 01EF7628: BFFF4000 4720C030 01C4 5BF0C8BC
47D0C04A.
PIPINX1198I Stage is active.
PIPMSG004I ... Issued from stage 5 of pipeline 1 name "siGh".
PIPMSG001I ... Running "Spec printonly a select second a: 1.3 . b: w2 .
c:".
DMSABE141T Operation exception occurred at 81EF7632 in routine PIPE

The stage in question:

'|Spec printonly a select second',
   'a: 1.3 . b: w2 . c: w3 .',
   'set (#0:=a*5;#1:=#0+4;#3+=1;#4+=b;#5:=#5" "c)',
   'break a',
   'print #0 pic v n /-/ n print #1 pic v n',
   'print #3 pic 9v 19.5 right',
   'print #4/#3 pic zzz9.v99 25',
   'print #5 35',
   'set (#3:=0;#4:=0;#5:="")',

It has taken the break once and produced the expected output.  I have a
dump, haven't yet analyzed it.
Thanks for any pointers
--
"Every palace and every work of art is only dust as yet unrealized, and
time is the patient wind that will wither it away." -- Dean Koontz, "The
Face"

Mike Harding
z/VM System Support

/sp


Re: [CMS-PIPELINES] Pipe Hostid issue

2015-07-13 Thread Michael Harding
CMSTSO Pipelines Discussion List  wrote on
07/13/2015 01:38:28 PM:

> From: Alan Altmark/Endicott/IBM@IBMUS
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/13/2015 01:38 PM
> Subject: Re: Pipe Hostid issue
> Sent by: CMSTSO Pipelines Discussion List 
>
> On Monday, 07/13/2015 at 04:30 EDT, Michael Harding/Oakland/IBM@IBMUS
> wrote:
> > Interestingly, on one of our internal "jumbo" systems where the host
> > returned by IDENTIFY will vary depending on one's cpuid as set up in
the
> > directory, the output from the socket(getname) call agrees with
identify
> in
> > the caller's machjne, while the pipe hostname stage returns what the
> stack
> > sees.
>
> Because both get their information from the TCPIP DATA file.  And when
> getting data from the TCPIP DATA file, the search is qualified by the NJE
> node node, which is determined by cpuid.
>
> Alan Altmark
>
> Senior Managing z/VM and Linux Consultant
> Lab Services System z Delivery Practice
> IBM Systems & Technology Group
> ibm.com/systems/services/labservices
> office: 607.429.3323
> mobile; 607.321.7556
> alan_altm...@us.ibm.com
> IBM Endicott
>
Except that I would have expected the socket call also to get the stack's
view of things or why bother?  Which also begs the question of how
pipelines does it if not a socket call.

--
Mike Harding
z/VM System Support

/sp


Re: [CMS-PIPELINES] Pipe Hostid issue

2015-07-13 Thread Michael Harding
CMSTSO Pipelines Discussion List  wrote on
07/13/2015 12:57:26 PM:

> From: Alan Altmark/Endicott/IBM@IBMUS
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/13/2015 12:57 PM
> Subject: Re: Pipe Hostid issue
> Sent by: CMSTSO Pipelines Discussion List 
>
> On Monday, 07/13/2015 at 02:38 EDT, Bob Cronin 
> wrote:
> > Thanks all for the pointer to PROFILE TCPIP. Seems there's some ongoing
> > project to add a second stack and for some reason they added the
> > non-routable 192.168.x.x address as the first one. I'm hoping they can
> move
> > it. Thanks also to Mike Harding who contacted me offline and schooled
me
> > about the NETSTAT HOME command.
>
> If they just add the PrimaryInterface statement, they don't need to worry
> about the order.  The problem with NETSTAT HOME is that you still don't
> know which interface is primary.
>
> And I should point out that the intent of (GET)HOSTID is not to return an
> IP address, but to return a 32-bit number that uniquely identifies a
host.
>  It turns out that a routable IPv4 address is a pretty good
approximation.
>
> Alan Altmark
>
> Senior Managing z/VM and Linux Consultant
> Lab Services System z Delivery Practice
> IBM Systems & Technology Group
> ibm.com/systems/services/labservices
> office: 607.429.3323
> mobile; 607.321.7556
> alan_altm...@us.ibm.com
> IBM Endicott
>
This bit got me thinking - and playing.

Interestingly, on one of our internal "jumbo" systems where the host
returned by IDENTIFY will vary depending on one's cpuid as set up in the
directory, the output from the socket(getname) call agrees with identify in
the caller's machjne, while the pipe hostname stage returns what the stack
sees.

--
Mike Harding
z/VM System Support
/sp



Re: [CMS-PIPELINES] Output to the bit bucket

2015-07-07 Thread Michael Harding
Don't even need to do that.

 'pipe (endchar ?)',
  'stem BST.',
  '| l: lookup',
  '?',
  'stem VSE.',
  '| l:',
  '?',
  'l:',
  '| specs /T:/ 1 1-* next',
  '| console'


--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
07/07/2015 02:09:27 PM:

> From: Mike Walter 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 07/07/2015 02:10 PM
> Subject: Re: Output to the bit bucket
> Sent by: CMSTSO Pipelines Discussion List 
>
> Mark,
>
> Could you mean that you want to dump the bits into a HOLE?  (hint,
> hint - look for the HOLE stage)
>
> Mike Walter
> Aon Service Corporation
> The opinions expressed herein are mine alone, not necessarily those
> of my employer.
>
>
>
>
> -Original Message-
> From: CMSTSO Pipelines Discussion List
[mailto:CMS-PIPELINES@VM.MARIST.EDU
> ] On Behalf Of Mark Pace
> Sent: Tuesday, July 07, 2015 16:06
> To: CMS-PIPELINES@VM.MARIST.EDU
> Subject: Output to the bit bucket
>
> I'm doing a lookup - but I don't want output from the Primary and
> Seconday, I only want to see the Tertiary output.  What can I put in
> place of the console stage to send the output to the bit bucket?
>
> 'pipe (endchar ?)',
>  'stem BST.',
>  '| l: lookup',
>  '| specs /P:/ 1 1-* next',
>  '| console',
>  '?',
>  'stem VSE.',
>  '| l:',
>  '| specs /S:/ 1 1-* next',
>  '| console',
>  '?',
>  'l:',
>  '| specs /T:/ 1 1-* next',
>  '| console'
>
> --
> The postings on this site are my own and don’t necessarily represent
> Mainline’s positions or opinions
>
> Mark D Pace
> Senior Systems Engineer
> Mainline Information Systems

[CMS-PIPELINES] Spec abend

2014-11-07 Thread Michael Harding
Coming out of starmsg, originally I had
...
'|Spec 17-* strip n',
...
Fine, until I decided I wanted to retain leading blanks.  Trying to be
clever, I coded
...
'|Spec a: 17-* . set #0:=Strip(a,"T"," ") print #0 n',
...
Well that produced a surprise:
PIPINX410E ABEND 00C5 at 01EF7024; PSW 03EC1000 81EF7024 00040005.
PIPINX411I ... In FPLSPSRL; offset 089C in FPLSPS 01/23/11 12.44.
PIPINX412I ... GPR0: 01956400 01956FE8 01F4D4C0 0003.
PIPINX412I ... GPR4: 03E9A1E0 0001 0020 01F4AC14.
PIPINX412I ... GPR8: 01F4CD40 01F4A110 01F4CD20 019562E0.
PIPINX412I ... GPRC: 81EF6FFC 01956F98 81EF700C .
PIPINX413I ... Store 01EF7018: 54208004 4142A000 BFFF4000 4720C030
01C4.
PIPINX1198I Stage is active.
PIPMSG004I ... Issued from stage 2 of pipeline 3 name "GetSMsgResp".
PIPMSG001I ... Running "Spec a: 17-* . set #0:=Strip(a,"T"," ") print #0
n".
DMSABE141T Addressing exception occurred at 81EF7024 in routine PIPE
CMS
Aha! I thought, I need to explicitly indicate we're dealing with a string -
been there, done that.
So I changed to
...
'|Spec a: 17-* . set #0:=String(Strip(a,"T"," ")) print #0 n',
...
Same result, so for good measure reversed the function nesting: set
#0:=Strip(String(a),"T"," ") and still got the abend.

Curiously, when I use the same constructions in a simple "pipe literal
asdfads|Spec a: etc" they behave as expected.
This is all with plastic pipes, I haven't tried with the product version.

Settling on expediency, I eventually just said  the trailing
blanks and changed to a "not chop 16".  My issue resolved.
--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
/sp


Re: [CMS-PIPELINES] Gate behavior

2014-11-03 Thread Michael Harding
In your original (iirc) the stage between starmsg and gate was keeping
starmsg from seeing its output severed, so it would have waited forever (or
until a pipestop).

--
Mike Harding
z/VM System Support

/sp


CMSTSO Pipelines Discussion List  wrote on
11/03/2014 01:02:07 PM:

> From: Bob Cronin 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 11/03/2014 01:03 PM
> Subject: Re: Gate behavior
> Sent by: CMSTSO Pipelines Discussion List 
>
> I've got just one last question. Does it seem reasonable behavior for the
> original (admittedly flawed) pipeline I posted to end up waiting forever
> when there was no response from RSCS? What exactly was it waiting for?
> --
> bc
>
> On Mon, Nov 3, 2014 at 2:27 PM, Bob Cronin  wrote:
>
> > I guess what I was missing is that TOTARGET finding the end-of-response
> > line would terminate the STARMSG. I thought I had to force the gate
closed
> > when that happened.
> > --
> > bc
> >
> > On Mon, Nov 3, 2014 at 2:05 PM, Glenn Knickerbocker 
> > wrote:
> >
> >> On 11/1/2014 6:11 PM, Bob Cronin wrote:
> >> > Since the whole point of the pipe is to trap the query response and
> >> process
> >> > it (and secondarily to complete as soon as the end of response is
seen,
> >> or
> >> > 5 seconds max if not), totarget seemed the logical choice. I'm not
sure
> >> I
> >> > see how to achieve the same thing in as clear a way in the fashion
you
> >> > suggest.
> >>
> >> Just replace TOTARGET with NOT.
> >>
> >> In your pipeline, you're splitting the file once at "End of command
> >> response" with TOTARGET, and then feeding the first line of the second
> >> part to GATE to split it again at the same point.  Essentially, you're
> >> using two GATEs to do the same thing.
> >>
> >> Instead, you can just send that one line to the primary of GATE, to
stop
> >> reading right there.  It doesn't matter which stream the rest of the
> >> file after that would have gone to, because you'll never read it.
> >>
> >> Alternatively, instead of using FANINANY to combine the inputs to the
> >> one GATE, you could use TOTARGET to watch for the end of the response
> >> and GATE for the timeout.  But you have to be careful to put them in
the
> >> order that you saw worked before, so that the timeout successfully
> >> severs the output of STARMSG:
> >>
> >> > pipe (end ?) strliteral /+5/
> >> >   | delay
> >> >   | b: gate
> >> >   ? starmsg cp smsg rscs the-query
> >> >   | b:
> >> >   | c: totarget pick w-4;* == /End of command response/
> >> >
> >>
> >> And if whatever's downstream severs its input before the end of the
> >> response, you'll see the same problem again, but mitigated by the
> >> successful timeout:  EOF won't propagate upstream through TOTARGET,
and
> >> you'll wind up waiting for the timeout.
> >>
> >> ¬R
> >>
> >
> >
>

Re: [CMS-PIPELINES] Assert failure?

2014-09-08 Thread Michael Harding
Just a hunch, based on John's statement referencing threads, my own
observation that ping and other programs having the problem seem to be
LE-based, and some reading of the LE Programmer's Guide.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
09/08/2014 01:53:11 PM:

> From: "Ackerman, Alan" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 09/08/2014 01:53 PM
> Subject: Re: Assert failure?
> Sent by: CMSTSO Pipelines Discussion List 
>
> Same here. Where did you get the POSIX(OFF)?
>
> I cannot find it in either HELP TCPIP PING or PIPE AHELP COMMAND.
>
> PIPE COMMAND PING POSIX(OFF) / zvmxp30040 | CONS
> Ping Level 620: Pinging host ZVMXP30040 (165.36.189.70).
> Enter #CP EXT to interrupt.
> PING: Ping #1 response took 0.034 seconds. Successes so far 1.
> ; T=0.01/0.01 13:46:05
> PIPE COMMAND PING/ zvmxp30040 | CONS
> FPLINX409E Assert failure 01C6 at 01A4F582.
> FPLINX411I ... In CMSCMD; offset 0B0A in FPLCOM 11/18/11 12.33.
> FPLINX412I ... GPR0:  00E7C858 01F6AFD8 001D.
> FPLINX412I ... GPR4:   3402000F 01F6AD18.
> FPLINX412I ... GPR8:  01F47230 01F6C518 00E7C710.
> FPLINX412I ... GPRC: 81A4F4D4 00E7CEB0 81A4F572 .
> FPLINX413I ... Store 01A4F578: 58009644 4780C0B0 01C6 9104B13E
47E0C0BC.
> DMSABE141T Operation exception occurred at 81A4F582 in routine PIPE
> CMS
>
> -Original Message-
> From: CMSTSO Pipelines Discussion List
[mailto:CMS-PIPELINES@vm.marist.edu
> ] On Behalf Of Michael Harding
> Sent: Monday, September 08, 2014 1:29 PM
> To: CMS-PIPELINES@vm.marist.edu
> Subject: Re: [CMS-PIPELINES] Assert failure?
>
> Poking around a bit more, and based on my own LE comment, I discovered
that
> most at least of the problem children run ok if the LE runtime option
POSIX
> (OFF) is specified.
>
> That is, where "PIPE COMMAND PING somehost | CONS" gets the assert
failure,
> "PIPE COMMAND PING POSIX(OFF) / somehost | CONS" doesn't.
>
> --
> Mike Harding
> z/VM System Support
> /sp
>
>
> CMSTSO Pipelines Discussion List  wrote on
> 09/08/2014 12:36:18 PM:
>
> > From: Michael Harding/Oakland/IBM@IBMUS
> > To: CMS-PIPELINES@VM.MARIST.EDU
> > Date: 09/08/2014 12:36 PM
> > Subject: Re: Assert failure?
> > Sent by: CMSTSO Pipelines Discussion List 
> >
> > Actually, NETSTAT is fine.  The problem seems to occur with many of the
> LE
> > modules on the tcpip public disk.
> >
> > CMSTSO Pipelines Discussion List  wrote on
> > 09/08/2014 12:14:21 PM:
> >
> > > From: "John P. Hartmann" 
> > > To: CMS-PIPELINES@VM.MARIST.EDU
> > > Date: 09/08/2014 12:18 PM
> > > Subject: Re: Assert failure?
> > > Sent by: CMSTSO Pipelines Discussion List

> > >
> > > Can reproduce on 5.2.
> > >
> > > The assert means:
> > >
> > > :dt.1C6:dd.FPLCOM
> > >
> > > CMS command destroyed pointer to pipeline set running :fref command.
or
> > > :fref cms.
> > >
> > > So perhaps NETSTAT is trying to multitask or does something it
> shouldn't
> > > have done to be able to run its own pipeline.  Or perhaps NETSTAT
drops
> > > the current pipeline to load the standard CMS one.  Perhaps you can
ask
> > > around?
> > >
> > > The actual test is whether the pipeline header pointer for the thread
> > > survives the command.  In this case there is no pipeline header
> > > associated with the thread after the command (R0) and there [clearly]
> > > was one before the command (R10).
> > >
> > > I added the assert in November, 2011, so DMSPIPE won't have that
> > > failure, but it is likely to have another one.  Did you try?
> > >
> > > On 09/08/2014 08:34 PM, Bob Cronin wrote:
> > > > pipe command PING 9.80.104.193 | console
> > >
> >
>
> --
> This message, and any attachments, is for the intended recipient(s)
> only, may contain information that is privileged, confidential and/
> or proprietary and subject to important terms and conditions available at

> http://www.bankofamerica.com/emaildisclaimer.   If you are not the
> intended recipient, please delete this message.
>


Re: [CMS-PIPELINES] Assert failure?

2014-09-08 Thread Michael Harding
Poking around a bit more, and based on my own LE comment, I discovered that
most at least of the problem children run ok if the LE runtime option POSIX
(OFF) is specified.

That is, where "PIPE COMMAND PING somehost | CONS" gets the assert failure,
"PIPE COMMAND PING POSIX(OFF) / somehost | CONS" doesn't.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
09/08/2014 12:36:18 PM:

> From: Michael Harding/Oakland/IBM@IBMUS
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 09/08/2014 12:36 PM
> Subject: Re: Assert failure?
> Sent by: CMSTSO Pipelines Discussion List 
>
> Actually, NETSTAT is fine.  The problem seems to occur with many of the
LE
> modules on the tcpip public disk.
>
> CMSTSO Pipelines Discussion List  wrote on
> 09/08/2014 12:14:21 PM:
>
> > From: "John P. Hartmann" 
> > To: CMS-PIPELINES@VM.MARIST.EDU
> > Date: 09/08/2014 12:18 PM
> > Subject: Re: Assert failure?
> > Sent by: CMSTSO Pipelines Discussion List 
> >
> > Can reproduce on 5.2.
> >
> > The assert means:
> >
> > :dt.1C6:dd.FPLCOM
> >
> > CMS command destroyed pointer to pipeline set running :fref command. or
> > :fref cms.
> >
> > So perhaps NETSTAT is trying to multitask or does something it
shouldn't
> > have done to be able to run its own pipeline.  Or perhaps NETSTAT drops
> > the current pipeline to load the standard CMS one.  Perhaps you can ask
> > around?
> >
> > The actual test is whether the pipeline header pointer for the thread
> > survives the command.  In this case there is no pipeline header
> > associated with the thread after the command (R0) and there [clearly]
> > was one before the command (R10).
> >
> > I added the assert in November, 2011, so DMSPIPE won't have that
> > failure, but it is likely to have another one.  Did you try?
> >
> > On 09/08/2014 08:34 PM, Bob Cronin wrote:
> > > pipe command PING 9.80.104.193 | console
> >
>


Re: [CMS-PIPELINES] Assert failure?

2014-09-08 Thread Michael Harding
Actually, NETSTAT is fine.  The problem seems to occur with many of the LE
modules on the tcpip public disk.

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
/sp


CMSTSO Pipelines Discussion List  wrote on
09/08/2014 12:14:21 PM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 09/08/2014 12:18 PM
> Subject: Re: Assert failure?
> Sent by: CMSTSO Pipelines Discussion List 
>
> Can reproduce on 5.2.
>
> The assert means:
>
> :dt.1C6:dd.FPLCOM
>
> CMS command destroyed pointer to pipeline set running :fref command. or
> :fref cms.
>
> So perhaps NETSTAT is trying to multitask or does something it shouldn't
> have done to be able to run its own pipeline.  Or perhaps NETSTAT drops
> the current pipeline to load the standard CMS one.  Perhaps you can ask
> around?
>
> The actual test is whether the pipeline header pointer for the thread
> survives the command.  In this case there is no pipeline header
> associated with the thread after the command (R0) and there [clearly]
> was one before the command (R10).
>
> I added the assert in November, 2011, so DMSPIPE won't have that
> failure, but it is likely to have another one.  Did you try?
>
> On 09/08/2014 08:34 PM, Bob Cronin wrote:
> > pipe command PING 9.80.104.193 | console
>


Re: [CMS-PIPELINES] Trying to use the Locate

2014-07-23 Thread Michael Harding
I think you're expecting the results to flow out of the "bottom" of the
pipe.  If you moved the ">" stage after the faninany (dropping the ": a2"
connection) you'd probably have what you want.  That after all is where
you're feeding the records selected by the locates.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
07/23/2014 03:03:20 PM:

> From: Miguel Soltero Diaz 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 07/23/2014 03:04 PM
> Subject: Re: Trying to use the Locate
> Sent by: CMSTSO Pipelines Discussion List 
>
> Hi Ronald,
> After further review with All Stage, I couldn't find a way to
> specify the location of the codes 0690/1090. So it gave me all
> records where the codes were found.
>
> So, I tried again with LOCATE as suggested.
> I must be missing something important, because I got all input
> records, ignoring the Locate stage
>
> here is my code
> 'pipe (endchar ?)',
>   '< AUDIT EXTRCT1',
>   '| a1: locate (29-32) /0690/ ',
>   '| b: faninany',
>   '? a1:',
>   '| a2: locate (29-32) /1090/ ',
>   '| b: ',
>   '? a2:',
>   '|  > AUDIT SUBSET a '
>
> what am I missing?
>
> Thanks
>

Re: [CMS-PIPELINES] saving the last section I skipped

2014-07-02 Thread Michael Harding
Well, your doc says when dam senses a trigger it shorts ALL streams, and
indeed supplying a hole stage as primary output worked.  And with this
topology it can receive at most one primary stream record.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
07/01/2014 09:02:23 PM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 07/01/2014 09:04 PM
> Subject: Re: saving the last section I skipped
> Sent by: CMSTSO Pipelines Discussion List 
>
> You need to stick a buffer or an elastic before DAM.
>
> On 07/01/2014 09:37 PM, Michael Harding wrote:
> > Duh!  Need more sleep I reckon. Should have seen the first,
misunderstood
> > DAM's behavior (and a trailing hole stage took care of that).
> > Thanks again
> > --
> > Mike Harding
> > z/VM System Support
> > /sp
> >
> >
> > CMSTSO Pipelines Discussion List  wrote on
> > 07/01/2014 10:48:09 AM:
> >
> >> From: Glenn Knickerbocker 
> >> To: CMS-PIPELINES@vm.marist.edu
> >> Date: 07/01/2014 10:48 AM
> >> Subject: Re: saving the last section I skipped
> >> Sent by: CMSTSO Pipelines Discussion List

> >>
> >> On 7/1/2014 1:29 PM, Michael Harding wrote:
> >>> First, the second pick, matching against the cutoff time works for
the
> >>
> >>> case but doesn't seem to for the = case.
> >>
> >>>   '|Pick w2 >>= /'cutoff'/',
> >>
> >> Looks like the value of CUTOFF in your test case has a trailing blank,
> >> so it will never match a word.
> >>
> >>> Second, even though a record is obviously flowing to the Dam, the
line
> >>> count (var gotem) is always zero, which you can see inserting a cons
> > stage
> >>> in front of the var stage.
> >>
> >>>   '|ga:Count lines',
> >>>   '|dd:Dam',
> >>
> >> It flows *to* but not *into* the DAM.  It's left in the pipeline, so
> >> COUNT doesn't count it as having gone through.
> >>
> >> ¬R
> >>
> >
>

Re: [CMS-PIPELINES] saving the last section I skipped

2014-07-01 Thread Michael Harding
Duh!  Need more sleep I reckon. Should have seen the first, misunderstood
DAM's behavior (and a trailing hole stage took care of that).
Thanks again
--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
07/01/2014 10:48:09 AM:

> From: Glenn Knickerbocker 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 07/01/2014 10:48 AM
> Subject: Re: saving the last section I skipped
> Sent by: CMSTSO Pipelines Discussion List 
>
> On 7/1/2014 1:29 PM, Michael Harding wrote:
> > First, the second pick, matching against the cutoff time works for the
>
> > case but doesn't seem to for the = case.
>
> >   '|Pick w2 >>= /'cutoff'/',
>
> Looks like the value of CUTOFF in your test case has a trailing blank,
> so it will never match a word.
>
> > Second, even though a record is obviously flowing to the Dam, the line
> > count (var gotem) is always zero, which you can see inserting a cons
stage
> > in front of the var stage.
>
> >   '|ga:Count lines',
> >   '|dd:Dam',
>
> It flows *to* but not *into* the DAM.  It's left in the pipeline, so
> COUNT doesn't count it as having gone through.
>
> ¬R
>

Re: [CMS-PIPELINES] saving the last section I skipped

2014-07-01 Thread Michael Harding
CMSTSO Pipelines Discussion List  wrote on
07/01/2014 09:47:49 AM:

> From: Glenn Knickerbocker 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 07/01/2014 09:48 AM
> Subject: Re: saving the last section I skipped
> Sent by: CMSTSO Pipelines Discussion List 
>
> On 6/30/2014 8:00 PM, I wrote:
> > I'm thinking I could use |BUFFER 1| to delay the contents of the
> > transaction until the timestamp arrives, but timing the insertion of my
> > target timestamp gets awfully messy.
>
> It actually turned out to be simpler to code than I thought, but I wound
> up doing the buffering on the whole file, rather than just the part
> before my target timestamp.  I MERGEd in the target, then PICKed it back
> out, then added it back in downstream of the BUFFER so it would arrive
> just before the previous buffered group of records.
>
> What if I split this into two problems?  MERGE|TOTARGET splits the file
> in two before the target timestamp.  Now how I would I take the section
> after the last timestamp in the first file?  I guess Rob's idea of using
> JOINCONT to make single records is what I've done in the past.
>
> ¬R
>

Maybe I missed something in the problem statement...
Based on how I read your original post - and admittedly just playing - I
quickly came up with

/* *GK Rexx* */
Parse arg cutoff
Signal on Error
Do forever
   'Peekto'   /* anybody home? */
   'CallPipe (End ? Name batch-em)',
 '*:|Pick to after 1.6 == /:time:/',
  '|a:Fanout',
  '|take last',
  '|Pick w2 >>= /'cutoff'/',
  '|ga:Count lines',
  '|dd:Dam',
  '?a:',
  '|Buffer',
  '|dd:',
  '|*:',
  '?ga:',
  '|var gotem'
   If gotem then Do
  'Short'
  Leave
  End
   End
Error: Exit Rc*(Rc<>12)

And it works, but came up with a couple of anomalies, that perhaps someone
can explain.
First, the second pick, matching against the cutoff time works for the >
case but doesn't seem to for the = case.
Second, even though a record is obviously flowing to the Dam, the line
count (var gotem) is always zero, which you can see inserting a cons stage
in front of the var stage.

Here's a drive exec if someone wants to play:
/*
**  GKT Exec
*/
Address Command
td.1 = 'batch1 record1'
td.2 = 'batch1 record2'
td.3 = 'batch1 record3'
td.4 = 'batch1 record4'
td.5 = ':time: 08:11:13 end of batch1'
td.6 = 'batch2 record1'
td.7 = 'batch2 record2'
td.8 = 'batch2 record3'
td.9 = 'batch2 record4'
td.10 = ':time: 08:13:13 end of batch2'
td.11 = 'batch3 record1'
td.12 = 'batch3 record2'
td.13 = 'batch3 record3'
td.14 = 'batch3 record4'
td.15 = ':time: 08:17:13 end of batch3'
td.16 = 'batch4 record1'
td.17 = 'batch4 record2'
td.18 = 'batch4 record3'
td.19 = 'batch4 record4'
td.20 = ':time: 08:21:13 end of batch4'
td.21 = 'batch5 record1'
td.22 = 'batch5 record2'
td.23 = 'batch5 record3'
td.24 = 'batch5 record4'
td.25 = ':time: 09:21:13 end of batch5'
td.0 = 25

Arg when

'PIPE (End ? Name GK_Test)',
' Stem td.',
'|Rexx gk' when,
'|Cons'
Exit Rc

When called with, for example "gkt 08:16:00", it correctly outputs batches
3 - 5, but "gkt 08:17:13" only outputs 4 & 5.

Thanks for any insights,
--
Mike Harding
z/VM System Support

/sp


Re: [CMS-PIPELINES] need a SPECS guru

2014-06-27 Thread Michael Harding
Your last case has always bugged me, but the "official" explanation was
that the query command succeeded, hence the RC 0.  Use "STATE * * R" to get
the desired behavior.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
06/27/2014 11:26:06 AM:

> From: Paul Gilmartin 
>
>  rexx address command "QUERY DISK R"; say RC

> Disk R not accessed

> 0

> Ready; T=0.01/0.01 12:23:02
>
> Ugh!  Error message not suppressed, and RC=0.
>
> -- gil
>

Re: [CMS-PIPELINES] abend in z/CMS

2014-06-25 Thread Michael Harding
IMO there's an incompatibility between something in the LE support and
plastic pipes.  I suffered similar abends a couple of years ago calling
LDAPSRCH (GLDSRCH module) from a pipe until I reverted to the product (ESA)
version of pipelines.  I beat on it a while, and discussed it with John,
but eventually just made sure the SVM involved stayed with the product
version.  This was z/VM 5.4 and 32-bit CMS, but the abends still occur at
6.2 or 6.3, 32- or 64-bit CMS.  At least with CMS27 (6.3) it first throws
an Assert Failure.

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
06/25/2014 11:14:09 AM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 06/25/2014 11:14 AM
> Subject: Re: abend in z/CMS
> Sent by: CMSTSO Pipelines Discussion List 
>
> Or maybe have a GLOBALV EXEC on your A-disk that does not produce more
than
> 1 line of output... ;-)
>
> If this is how they access the GLOBALV variables, I'm not sure I want to
> sit next to them at dinner (sharp steak knifes etc)
>
>
> On 25 June 2014 20:08, Glenn Knickerbocker  wrote:
>
> > On 6/25/2014 8:08 AM, Jonathan Scott wrote:
> > >  PIPE ( ENDCHAR ? )
> > >CMS GLOBALV SELECT CENV LIST
> > >  | DROP FIRST 1
> > >  | STRIP LEADING BLANK 1
> > >  | APPEND LITERAL
> > >  | JOIN * H00
> > >  | STORAGE 06B7CC28 300 E0
> > >  | COUNT BYTES
> > >  | STORAGE 06B7C7F0 11 E0
> >
> > D'oh!  I don't know why it didn't occur to me that the compiler module
> > would be CALLING Pipelines.  That makes the PUSH workaround make sense.
> >
> > ¬R
> >
>

Re: [CMS-PIPELINES] SPEC with multiple IFs.

2014-04-25 Thread Michael Harding
Where's that "like" button?

--
Mike Harding
z/VM System Support
/sp


CMSTSO Pipelines Discussion List  wrote on
04/25/2014 07:24:30 AM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 04/25/2014 07:24 AM
> Subject: Re: SPEC with multiple IFs.
> Sent by: CMSTSO Pipelines Discussion List 
>
> I hate to be a spoilsport, but how about reading the documentation that
> applies to the version of CMS/TSO Pipelines you are using?
>


Re: [CMS-PIPELINES] SPEC with multiple IFs.

2014-04-24 Thread Michael Harding
I think this is one of those cases where specs requires that a string be
delimited specifically with double quotes.

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
/sp


CMSTSO Pipelines Discussion List  wrote on
04/24/2014 01:40:29 PM:

> From: "Frank M. Ramaekers" 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 04/24/2014 01:41 PM
> Subject: Re: SPEC with multiple IFs.
> Sent by: CMSTSO Pipelines Discussion List 
>
> After correcting the missing comma and using ELSEIF, it ends with a
cryptic:
>
>
>
>   "|  SPEC /UAGLOBE/ 1.8 1-* NW RECNO FROM" X2D(F800) "D2X NW.4
> RIGHT a: 6.3 .",
>
>   "IF a==/MOD/ THEN",

>
> "/C/ NW",

>
>   "ELSEIF a==/MVS/ THEN",

>
> "/C/ NW",

>
>   "ELSE",

>
> "/R/ NW",

>
>   "ENDIF",

>
> PIPYAC1434E Parse error in state 137, unexpected O_MULT at offset 3:
> "/MOD/ THEN /C/ NW ELSEIF a==/MVS/ THEN /C/ NW ELSE /R/ NW ENDI
>
> F".

>
> PIPMSG003I ... Issued from stage 2 of pipeline 11.

>
> PIPMSG001I ... Running "SPEC /UAGLOBE/ 1.8 1-* NW RECNO FROM 63488
> D2X NW.".
>
> PIPYAC1435I Expecting T_IDLETTER T_NUMBER T_QSTRING T_IDENT
> T_ID_CHAR T_CTR T_DOT T_DOTDOT T_CTRARRAY S_LP O_PLUS O_NOT F_FIRST F_EO
>
> F F_BREAK F_C2D F_C2F F_X2D F_X2F F_STRING F_AVERAGE F_VARIANCE
> F_NUMBER F_EXACT F_SQRT F_STDDEV F_STDERRMEA
>
> PIPSPE192I ... Scan at position 69; previous data "OM 63488 D2X NW.4
> RIGHT a: 6.3 . IF a==/".
>
>
>
> Frank M. Ramaekers Jr.
>
>
>
>
>
> > -Original Message-
>
> > From: CMSTSO Pipelines Discussion List [mailto:CMS-
>
> > pipeli...@vm.marist.edu] On Behalf Of Kris Buelens
>
> > Sent: Thursday, April 24, 2014 3:24 PM
>
> > To: CMS-PIPELINES@VM.MARIST.EDU
>
> > Subject: Re: [CMS-PIPELINES] SPEC with multiple IFs.
>
> >
>
> > I don't know if that will help: PIPE alos has ean ELSEIF
>
> >
>
> >   "ELSEIF a==/MVS/ THEN",
>
> >   "/C/ NW",
>
> >
>
> >
>
> > Kris Buelens,
>
> >  --- freelance z/VM consultant, Belgium ---
>
> > ---
>
> >
>
> >
>
> > 2014-04-24 22:19 GMT+02:00 Joe Parker  mailto:jgp4...@hotmail.com> >:
>
> >
>
> > > Well, it's been quite a few years since I wrote any pipe code,
but
>
> > > could it be there's a comma missing in the first line?
>
> > >
>
> > > > Date: Thu, 24 Apr 2014 15:13:22 -0500
>
> > > > From: framaek...@ailife.com 
>
> > > > Subject: SPEC with multiple IFs.
>
> > > > To: CMS-PIPELINES@VM.MARIST.EDU

>
> > > >
>
> > > > I can't seem to find information on what could be wrong with this:
>
> > > >
>
> > > >
>
> > > >
>
> > > > "|  SPEC // 1.8 1-* NW RECNO FROM" X2D(F800) "D2X NW.4 RIGHT a:
>
> > > > 6.3 ."
>
> > > >
>
> > > >   "IF a==/MOD/ THEN",
>
> > > >
>
> > > > "/C/ NW",
>
> > > >
>
> > > >   "ELSE",
>
> > > >
>
> > > > "IF a==/MVS/ THEN",
>
> > > >
>
> > > >   "/C/ NW",
>
> > > >
>
> > > > "ELSE",
>
> > > >
>
> > > >   "/R/ NW",
>
> > > >
>
> > > > "ENDIF",
>
> > > >
>
> > > >   "ENDIF",
>
> > > >
>
> > > >
>
> > > >
>
> > > > I'm not getting the output I expect (I don't see PIPE flagging
>
> > > > anything).   I've only had single IF's in the past.
>
> > > >
>
> > > >
>
> > > >
>
> > > > Frank M. Ramaekers Jr. | Systems Programmer | Information
Technology
>
> > > > | American Income Life Insurance Company | 254-761-6649
>
> > > >
>
> > > >
>
> > >
>
> > >
>

Re: [CMS-PIPELINES] Replace/overlay record #

2014-04-13 Thread Michael Harding
First I'll point out that the replace and modify examples are redundant.
For a replacement situation just specify the entire replacement string in
the modify example's specs stage.
The same's true of Rob's solution, where the replace is limited case of
modify.  For a more complex modification you might code the specs stage in
your control record and pass it to callpipe.

--
Mike Harding
z/VM System Support

/sp


CMSTSO Pipelines Discussion List  wrote on
04/11/2014 11:11:31 PM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@vm.marist.edu,
> Date: 04/12/2014 04:11 AM
> Subject: Re: Replace/overlay record #
> Sent by: CMSTSO Pipelines Discussion List 
>
> I would use 'collate' with the record number as the key. You prefix each
> input record with the 10-byte record number and have the master
streamwith
> replacements also tagged with record number to replace. You could use
plain
> record numbers (so no data) as deletion (use a locate 1 afterwards to
> filter null records out) and some out-of-order record number would let
you
> insert something.
>
> Rob
>
>
> On 12 April 2014 04:25, Frank M. Ramaekers  wrote:
>
> > Okay plumbers, I have a stream and I know which record number I want to
> > replace or modify.  Is there some easier method than
> >
> > REPLACE:
> >
> > PIPE (endchar ?) ... f:TAKE FIRST n-1 | DROP FIRST 1 | PREFACE
> > STRLITERAL ... |i:FANINANY ...?f:|i:
> >
> >
> >
> > MODIFY
> >
> > PIPE (endchar ?) ... f:TAKE FIRST n-1 |g:TAKE FIRST 1 | SPEC /*/ 1 1-*
N
> > |i:FANINANY...?f:|i:?g:i:
> >
> >
> >
> >
> >
> > Frank M. Ramaekers Jr. | Systems Programmer | Information Technology |
> > American Income Life Insurance Company | 254-761-6649
> >
> >
> >
>


Re: [CMS-PIPELINES] I'm stumped

2013-09-05 Thread Michael Harding
Well, I thought "printonly eof" was a stage option rather than a break, and
the latter "eof" following the if clause sets the break action.  There
aren't any field definitions after that one.
Too, from what you're saying it should complain about the definition of a:,
when instead it seems to be complaining about the definition of b: within
the if clause.

So I removed the printonly eof and the latter eof, just for grins, and got
the same error.  Completely flummoxed now...  Reviewing the Specs
reference, I did come across:
| Conditional groups cannot contain input sources that have identifiers, as
it
| is indeterminate, in general, whether the field has been defined or not.

So maybe that's the problem and the message 1037 was leading me down the
wrong path, except the only identifier being used as an input source was in
"if a>#1", so I put a in another counter prior to the if and tested that:
|Spec printonly EOF a: w3 . set (#0+=1;#5:=a)',
  'if #5>#1 then',
 'b: substr 1.8 of w2 . c: substr 9.6 of w2 .',
 'set (#1:=a;#2:=b;#3:=c) fi',
  'eof print #0 strip 5 /samples, max was/ nw print #1 strip nw',
 '/on/ nw print #2 strip nw /at/ nw print #3 strip nw',
Same error 1037, with or without the printonly and later eof.

Finally, taking all identifier references out of the if clause worked:
'|Spec printonly EOF a: w3 . b: substr 1.8 of w2 . c: substr 9.6 of w2 .',
   'set (#0+=1;#5:=a;#6:=b;#7:=c)',
   'if #5>#1 then',
  'set (#1:=a;#2:=#6;#3:=#7) fi',
   'eof print #0 strip 5 /samples, max was/ nw print #1 strip nw',
  '/on/ nw print #2 strip nw /at/ nw print #3 strip nw',

Seems unnecessarily tortuous to me, but then I'm not programming it
And, I would swear I've used similar code before, deciding how to parse a
record depending on the value of a fixed field.
I.e.... a: w1 . if a=="type1" then b:  10.3 . else b: 20.3 endif
Or maybe I just wrote a rexx stage...

Anyway, thanks for the response.
--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
/sp


CMSTSO Pipelines Discussion List  wrote on
09/05/2013 01:05:50 PM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@vm.marist.edu,
> Date: 09/05/2013 01:06 PM
> Subject: Re: I'm stumped
> Sent by: CMSTSO Pipelines Discussion List 
>
> Message 192 gives the game away. Wouldn't you say that EOF is a break?
>
> On 09/05/2013 09:05 PM, Michael Harding wrote:
> > This:
> > '|Spec printonly EOF a: w3 . set #0+=1',
> > 'if a>#1 then',
> >'b: substr 1.8 of w2 . c: substr 9.6 of w2 .',
> >'set (#1:=a;#2:=b;#3:=c) fi',
> > 'eof print #0 strip 5 /samples, max was/ nw print #1 strip nw',
> >'/on/ nw print #2 strip nw /at/ nw print #3 strip nw',
> >
> > causes:
> > PIPSPE1037E Field identifiers cannot be defined in break items.
> > PIPMSG004I ... Issued from stage 2 of pipeline 2 name
"pageRate_alerts".
> > PIPMSG001I ... Running "Spec printonly EOF a: w3 . set #0+=1 if a>#1
then".
> > PIPSPE192I ... Scan at position 31; previous data "a: w3 . set #0+=1 if
> > a>#1 then".
> >
> > and I just can't see it, unless the if...fi clause is considered a
break
> > item.  No complaints without it though.
> >   And I've certainly defined field identifiers within if clauses
before,
> > just not in conjunction with a printonly option.
> >
> > Suggestions?
> > Thanks,
> > --
> > Mike Harding
> > z/VM System Support
> >
> > /sp
>

[CMS-PIPELINES] I'm stumped

2013-09-05 Thread Michael Harding
This:
'|Spec printonly EOF a: w3 . set #0+=1',
   'if a>#1 then',
  'b: substr 1.8 of w2 . c: substr 9.6 of w2 .',
  'set (#1:=a;#2:=b;#3:=c) fi',
   'eof print #0 strip 5 /samples, max was/ nw print #1 strip nw',
  '/on/ nw print #2 strip nw /at/ nw print #3 strip nw',

causes:
PIPSPE1037E Field identifiers cannot be defined in break items.
PIPMSG004I ... Issued from stage 2 of pipeline 2 name "pageRate_alerts".
PIPMSG001I ... Running "Spec printonly EOF a: w3 . set #0+=1 if a>#1 then".
PIPSPE192I ... Scan at position 31; previous data "a: w3 . set #0+=1 if
a>#1 then".

and I just can't see it, unless the if...fi clause is considered a break
item.  No complaints without it though.
 And I've certainly defined field identifiers within if clauses before,
just not in conjunction with a printonly option.

Suggestions?
Thanks,
--
Mike Harding
z/VM System Support

/sp


Re: [CMS-PIPELINES] Help with DIRECTORY pipe

2013-08-28 Thread Michael Harding
"something":
'| Spec w1-7 n a: w8 . b: w9 . c: w10 . if a^=="" then // nw if
b^=="" then /xxx/ nw if c^=="" then /xxx/ nw fi fi fi'

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
/sp


CMSTSO Pipelines Discussion List  wrote on
08/28/2013 01:16:20 PM:

> From: "Frank M. Ramaekers" 
> To: CMS-PIPELINES@vm.marist.edu,
> Date: 08/28/2013 01:17 PM
> Subject: Help with DIRECTORY pipe
> Sent by: CMSTSO Pipelines Discussion List 
>
> I want to go through the directory changing all USER statements with
> passwords to  and all MDISK passwords to  for storage on
> our DR site.
>
>
>
> For the MDISK statements I only want to replace the password if one
> exists, not insert one if it's omitted (blank).
>
>
>
> This is what I have so far:
>
>
>
>   "PIPE (endchar ?)",
>
>   "   <" !._InFile,
>
>   "|  SPEC 1-71 1",
>
>   "|  STRIP BOTH",
>
>   "|u:NOT ABBREV USER 1 ANYCASE",
>
>   "|m:NOT ABBREV MDISK 1 ANYCASE",
>
>   "|i:FANINANY",
>
>   "|  >" !._OutFile,
>
> "?u:",
>
>   "|l:ZONE W3 NFIND NOLOG"||,
>
>   "|p:ZONE W3 NFIND NOPASS"||,
>
>   "|a:ZONE W3 NFIND AUTOONLY"||,
>
>   "|b:ZONE W3 NFIND LBYONLY"||,
>
>   "|  SPEC W1-2 1 // NW W4-* NW",
>
>   "|  i:",
>
> "?l:",
>
>   "|  i:",
>
> "?p:",
>
>   "|  i:",
>
> "?a:",
>
>   "|  i:",
>
> "?b:",
>
>   "|  i:",
>
> "?m:",
>
>   "|  dosomething",
>
>   "| i:"
>
>
>
> Thoughts?  Ideas?
>
>
>
> Frank M. Ramaekers Jr. | Systems Programmer | Information Technology |
> American Income Life Insurance Company | 254-761-6649
>
>
>


Re: [CMS-PIPELINES] Trick needed

2013-07-22 Thread Michael Harding
Never mind, came up with an additional level of abstraction/indirection
that works as desired:
'|Spec a: w4 . b: w6 . Set (#0:=a;#1:=b) read',
   'a: w1 . set #2:=8-Length(a)',
  'while #0<=#1 Do',
 'set #3:=string(Right(#0,#2,"0"))',
 'w1 n print #3 n w2 nw w1 nw',
 'print #3 n w4-* nw',
 'if #0<#1 then write fi',
 'set #0+=1 done',


In short:

inp.1 = 'abc  pool low 1 high 4 include abcdef'
inp.2 = 'abc  identity abc autoonly G'
inp.3 = 'de   pool low 3 high 6 include some1'
inp.4 = 'de   user de lbyonly eg'
inp.5 = 'xpool low 16 high 23 include george'
inp.6 = 'xidentity x cantbe a valid password'
inp.0 = 6

'PIPE Stem inp.',
'|Spec a: w4 . b: w6 . Set (#0:=a;#1:=b) read',
   'a: w1 . set #2:=8-Length(a)',
  'while #0<=#1 Do',
 'set #3:=string(Right(#0,#2,"0"))',
 'w1 n print #3 n w2 nw w1 nw',
 'print #3 n w4-* nw',
 'if #0<#1 then write fi',
 'set #0+=1 done',
'|Cons'

produces:

abc1 identity abc1 G
abc2 identity abc2 G
abc3 identity abc3 G
abc4 identity abc4 G
de03 user de03 lbyonly eg
de04 user de04 lbyonly eg
de05 user de05 lbyonly eg
de06 user de06 lbyonly eg
x016 identity x016 cantbe a valid password
x017 identity x017 cantbe a valid password
x018 identity x018 cantbe a valid password
x019 identity x019 cantbe a valid password
x020 identity x020 cantbe a valid password
x021 identity x021 cantbe a valid password
x022 identity x022 cantbe a valid password
x023 identity x023 cantbe a valid password

--
Mike Harding
z/VM System Support

/sp


CMSTSO Pipelines Discussion List  wrote on
07/22/2013 03:48:12 PM:

> From: Michael Harding/Oakland/IBM@IBMUS
> To: CMS-PIPELINES@vm.marist.edu,
> Date: 07/22/2013 03:50 PM
> Subject: Trick needed
> Sent by: CMSTSO Pipelines Discussion List 
>
> How do you specify the size of an output object in specs at run time?
>
> I want to expand directory POOL statements myself.  I have:
>
> '|gpa:Lookup w1 master detail',  /* pull in any POOL records */
> '|Spec a: w4 . b: w6 . Set (#0:=a;#1:=b) read',  /* userid POOL LOW x
HIGH
> y ... */
>'a: w1 . set #2:=8-Length(a)',
>   'while #0<=#1 Do',
>  'w1 n print #0 n.(#2) right w2 nw w1 nw',
>  'print #0 n.(#2) right w4-* nw',
>  'if #0<#1 then write fi',
>  'set #0+=1 done',
>
> The intent is to take the userid from the USER or IDENTITY statement and
> produce as many USER or IDENTITY statements with the userid expanded it
to
> UUUn, UUnn or Unnn as specified by the POOL statement.
> The input to this has the USER/IDENTITY statement on the primary input to
> the lookup, the POOL statement on the secondary.  All statements have a
> 9-character prefix with the userid.
> The ultimate purpose is to end up with a file to match against a RACF LU
*
> to pick out userids without RACF profiles, and profiles that aren't in
the
> directory.
>
> I thought I'd seen, though of course can't remember or find where, the
> n.(#2) construct for output placement.
> It also doesn't work without the parens.
> Any thoughts?
> Tia,
> --
> Mike Harding
> z/VM System Support
>
> /sp


[CMS-PIPELINES] Trick needed

2013-07-22 Thread Michael Harding
How do you specify the size of an output object in specs at run time?

I want to expand directory POOL statements myself.  I have:

'|gpa:Lookup w1 master detail',  /* pull in any POOL records */
'|Spec a: w4 . b: w6 . Set (#0:=a;#1:=b) read',  /* userid POOL LOW x HIGH
y ... */
   'a: w1 . set #2:=8-Length(a)',
  'while #0<=#1 Do',
 'w1 n print #0 n.(#2) right w2 nw w1 nw',
 'print #0 n.(#2) right w4-* nw',
 'if #0<#1 then write fi',
 'set #0+=1 done',

The intent is to take the userid from the USER or IDENTITY statement and
produce as many USER or IDENTITY statements with the userid expanded it to
UUUn, UUnn or Unnn as specified by the POOL statement.
The input to this has the USER/IDENTITY statement on the primary input to
the lookup, the POOL statement on the secondary.  All statements have a
9-character prefix with the userid.
The ultimate purpose is to end up with a file to match against a RACF LU *
to pick out userids without RACF profiles, and profiles that aren't in the
directory.

I thought I'd seen, though of course can't remember or find where, the
n.(#2) construct for output placement.
It also doesn't work without the parens.
Any thoughts?
Tia,
--
Mike Harding
z/VM System Support

/sp

Re: [CMS-PIPELINES] Pick input range inconsistency

2012-12-28 Thread Michael Harding
And happy holidays to you too!  No offense taken, I was simply reading more
into the description of the "n+" syntax than is actually in the help.  I
should have realized you'd have used the same input-range parser as
elsewhere.  Once I deciphered the error message I could see that what was
going on was as you described.  Perhaps my subject was ill-considered, and
this should have fallen into the WIBNI category.

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
/sp


CMSTSO Pipelines Discussion List  wrote on
12/28/2012 10:46:57 AM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@vm.marist.edu,
> Date: 12/28/2012 10:48 AM
> Subject: Re: Pick input range inconsistency
> Sent by: CMSTSO Pipelines Discussion List 
>
> Season's greetings!
>
> I do not wish to offend, but it would appear that you don't understand
> what 1+ means and when it is appropriate.  Nor the finer points of
> substr.
>
> On 28 December 2012 19:28, Michael Harding  wrote:
> > I recognize 1+ isn't a valid input range, I was just surprised that
pick
> > didn't support the same notation with substring as without.  In my
actual
> > code the matching "constant" is a word of variable length coming from
> > another source.  Yes, I could reorder to put the input word of interest
> > first and use the "1+" notation; or there are several approaches, this
just
> > seemed the simplest had it worked.
> >
> > --
> > Mike Harding
> > z/VM System Support
> >
> > /sp
> >
> >
> > CMSTSO Pipelines Discussion List  wrote on
> > 12/28/2012 09:59:31 AM:
> >
> >> From: "John P. Hartmann" 
> >> To: CMS-PIPELINES@vm.marist.edu,
> >> Date: 12/28/2012 10:00 AM
> >> Subject: Re: Pick input range inconsistency
> >> Sent by: CMSTSO Pipelines Discussion List

> >>
> >> 1+ is not an inputRange; hence substr is not a substring, but the
> >> string ub delimited by s.  Try 1.3 instead.
> >>
> >> On 28 December 2012 18:36, Michael Harding 
wrote:
> >> > pipe literal abcdef 123456|pick 1+ == /abc/|cons
> >> > abcdef 123456
> >> > Ready; T=0.01/0.01 09:29:34
> >> > pipe literal abcdef 123456|pick 8+ == /123/|cons
> >> > abcdef 123456
> >> > Ready; T=0.01/0.01 09:29:57
> >> > pipe literal abcdef 123456|pick 8+ == /1234/|cons
> >> > abcdef 123456
> >> > Ready; T=0.01/0.01 09:30:25
> >> > pipe literal abcdef 123456|pick 8+ == /1235/|cons
> >> > Ready; T=0.01/0.01 09:30:31
> >> > pipe literal abcdef 123456|pick substr 1.3 of w2 == /123/|cons
> >> > abcdef 123456
> >> > Ready; T=0.01/0.01 09:31:08
> >> > pipe literal abcdef 123456|pick substr 1+ of w2 == /123/|cons
> >> > PIPPIC687E Relational operator expected; found tr.
> >> > PIPMSG003I ... Issued from stage 2 of pipeline 1.
> >> > PIPMSG001I ... Running "pick substr 1+ of w2 == /123/".
> >> > Ready(00687); T=0.01/0.01 09:31:27
> >> > pipe query version
> >> > PIPINX086I CMS/TSO Pipelines, 5654-030/5655-A17 1.0112
> >> > (Version.Release/Mod) - Generated 24 Jul 2012 at 06:07:28.
> >> > Ready; T=0.01/0.01 09:32:19
> >> >
> >> > Oops!
> >> > --
> >> > Mike Harding
> >> > z/VM System Support
> >> >
> >> > /sp
> >>
>

Re: [CMS-PIPELINES] Pick input range inconsistency

2012-12-28 Thread Michael Harding
I recognize 1+ isn't a valid input range, I was just surprised that pick
didn't support the same notation with substring as without.  In my actual
code the matching "constant" is a word of variable length coming from
another source.  Yes, I could reorder to put the input word of interest
first and use the "1+" notation; or there are several approaches, this just
seemed the simplest had it worked.

--
Mike Harding
z/VM System Support

/sp


CMSTSO Pipelines Discussion List  wrote on
12/28/2012 09:59:31 AM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@vm.marist.edu,
> Date: 12/28/2012 10:00 AM
> Subject: Re: Pick input range inconsistency
> Sent by: CMSTSO Pipelines Discussion List 
>
> 1+ is not an inputRange; hence substr is not a substring, but the
> string ub delimited by s.  Try 1.3 instead.
>
> On 28 December 2012 18:36, Michael Harding  wrote:
> > pipe literal abcdef 123456|pick 1+ == /abc/|cons
> > abcdef 123456
> > Ready; T=0.01/0.01 09:29:34
> > pipe literal abcdef 123456|pick 8+ == /123/|cons
> > abcdef 123456
> > Ready; T=0.01/0.01 09:29:57
> > pipe literal abcdef 123456|pick 8+ == /1234/|cons
> > abcdef 123456
> > Ready; T=0.01/0.01 09:30:25
> > pipe literal abcdef 123456|pick 8+ == /1235/|cons
> > Ready; T=0.01/0.01 09:30:31
> > pipe literal abcdef 123456|pick substr 1.3 of w2 == /123/|cons
> > abcdef 123456
> > Ready; T=0.01/0.01 09:31:08
> > pipe literal abcdef 123456|pick substr 1+ of w2 == /123/|cons
> > PIPPIC687E Relational operator expected; found tr.
> > PIPMSG003I ... Issued from stage 2 of pipeline 1.
> > PIPMSG001I ... Running "pick substr 1+ of w2 == /123/".
> > Ready(00687); T=0.01/0.01 09:31:27
> > pipe query version
> > PIPINX086I CMS/TSO Pipelines, 5654-030/5655-A17 1.0112
> > (Version.Release/Mod) - Generated 24 Jul 2012 at 06:07:28.
> > Ready; T=0.01/0.01 09:32:19
> >
> > Oops!
> > --
> > Mike Harding
> > z/VM System Support
> >
> > /sp
>

[CMS-PIPELINES] Pick input range inconsistency

2012-12-28 Thread Michael Harding
pipe literal abcdef 123456|pick 1+ == /abc/|cons
abcdef 123456
Ready; T=0.01/0.01 09:29:34
pipe literal abcdef 123456|pick 8+ == /123/|cons
abcdef 123456
Ready; T=0.01/0.01 09:29:57
pipe literal abcdef 123456|pick 8+ == /1234/|cons
abcdef 123456
Ready; T=0.01/0.01 09:30:25
pipe literal abcdef 123456|pick 8+ == /1235/|cons
Ready; T=0.01/0.01 09:30:31
pipe literal abcdef 123456|pick substr 1.3 of w2 == /123/|cons
abcdef 123456
Ready; T=0.01/0.01 09:31:08
pipe literal abcdef 123456|pick substr 1+ of w2 == /123/|cons
PIPPIC687E Relational operator expected; found tr.
PIPMSG003I ... Issued from stage 2 of pipeline 1.
PIPMSG001I ... Running "pick substr 1+ of w2 == /123/".
Ready(00687); T=0.01/0.01 09:31:27
pipe query version
PIPINX086I CMS/TSO Pipelines, 5654-030/5655-A17 1.0112
(Version.Release/Mod) - Generated 24 Jul 2012 at 06:07:28.
Ready; T=0.01/0.01 09:32:19

Oops!
--
Mike Harding
z/VM System Support

/sp


Re: [CMS-PIPELINES] Starmon suppress?

2012-01-09 Thread Michael Harding
I'm not discarding them, ESAWRITE  is still capturing them.  I was
just playing with getting my own look.
Yes, I've added the pick already, but if starmon will ignore the unwanted
ones on my behalf, that should save a good many trips through pipelines'
dispatching mechanism.

--
Mike Harding


CMSTSO Pipelines Discussion List  wrote on
01/09/2012 02:10:31 PM:

> From: Rob van der Heij 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 01/09/2012 02:12 PM
> Subject: Re: Starmon suppress?
> Sent by: CMSTSO Pipelines Discussion List 
>
> On Mon, Jan 9, 2012 at 9:19 PM, Michael Harding 
wrote:
> > Either I'm missing something or the SUPPRESS option on the STARMON
stage
> > isn't working.
> >
> > Being only interested in user domain records (domain 4), I have
"starmon
> > samples suppress F7FF", yet coming out of the stage I'm seeing:
> > Total Records       11739
> > Domain 4 Recs         486
> > Domain  0    339
> > Domain  1    885
> > Domain  3    279
> > Domain  4    486
> > Domain  5     39
> > Domain  6   9021
> > Domain  8    111
> > Domain 10    579
> >
> > Am I missing something?
> > Thanks,
> > --
> > Mike Harding
>
> Who would want to discard good monitor records :-)  But I think you're
> right that it does not work and all records pass through. Seems to me
> the necessary code to do that is misplaced or missing.
>
> You could put a "pick 5 == x04" behind the mondata stage to throw the
> rest away (a bit more expensive).
>
> Rob
>

[CMS-PIPELINES] Starmon suppress?

2012-01-09 Thread Michael Harding
Either I'm missing something or the SUPPRESS option on the STARMON stage
isn't working.

Being only interested in user domain records (domain 4), I have "starmon
samples suppress F7FF", yet coming out of the stage I'm seeing:
Total Records   11739
Domain 4 Recs 486
Domain  0339
Domain  1885
Domain  3279
Domain  4486
Domain  5 39
Domain  6   9021
Domain  8111
Domain 10579

Am I missing something?
Thanks,
--
Mike Harding


Re: [CMS-PIPELINES] Saving and restoring a reader file

2011-09-16 Thread Michael Harding
Basically correct, though there are complications.  While RDR will save the
tag and URO will output it, the tag setting will override and the original
file's tag will just be another record in the spool file (assuming you've
set NOPDATA on).  Here's a more complete solution:
It does require that the printer (00E) be spooled to your rdr.  A more
complete solution would save and manipulate the printer settings too.
/*
**
*/
Address Command
Arg fid
Parse value Diag(8,'QUERY SET') with . 'NOPDATA' pdset . ',' .
Parse value Diag(8,'SET NOPDATA ON') with .
'PIPE (End ? Name ReSpool)',
' <' fid,
'|a:Pick 1.1 == x03',
'|b:Take 1',
'|Spec 2-* n',
'|var tagset',
'?a:',
'|c:Faninany',
'|URO',
'?b:',
'|c:'
Parse value Diag(8,'CLOSE 00E NAME' Subword(fid,1,2)) with . . sfid .
If Symbol('tagset')='VAR' then
   Parse value Diag(8,'TAG FILE' sfid tagset) with .
Parse value Diag(8,'SET NOPDATA' pdset) with .
Exit 0

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
09/16/2011 09:19:38 AM:

> From: Paul Gilmartin 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 09/16/2011 09:23 AM
> Subject: Re: Saving and restoring a reader file
> Sent by: CMSTSO Pipelines Discussion List 
>
> On Sep 16, 2011, at 09:14, Bob Cronin wrote:
>
> > I need a way to take a reader file and save it to disk in such a way
that at
> > some later time, I can restore the file to the reader and have it be
> > identical to the original in all respects, including any tags (store
and
> > forward, or otherwise). Kind of like what SPTAPE does, but using CMS
> > minidisk to save the data and Rexx/Pipelines to do the work. Any
thoughts?
> >
> The READER stage returns a CCW code at the beginning of each record.
> It should be possible to write this to disk, and reconstitute it to
> spool with a URO stage.
>
> I haven't tried exactly this.
>
> -- gil

Re: [CMS-PIPELINES] printmc truncates lines

2011-08-26 Thread Michael Harding
Well...  I didn't try a full-size line, but after a "def vafp 30e"

pipe < profile exec b|join 16|insert x09|printmc 30e
Ready; T=0.01/0.01 15:08:40
close 30e
RDR FILE 7797 SENT FROM Q839420  PRT WAS 7797 RECS 0006 CPY  001 A NOHOLD
NOKEEP
Ready; T=0.01/0.01 15:08:45
receive 7797 wide file a (keepcc
DMSWRC738I Record length is 594 bytes
File WIDE FILE A1 received from Q839420 at ZVM0 sent as (none) (none) A
Ready; T=0.01/0.01 15:08:55

And it shows with that lrecl in a filelist, etc:
la wide file
FILENAME FILETYPE FM FORMAT LRECL   RECS BLOCKS   DATE TIME
LABEL
WIDE FILE A1 V594  6  1  8/26/11 15:08:55
MBH191
Ready; T=0.01/0.01 15:12:39
pipe (End ?) < wide file a|take 5|a:Fanout|spec 1.1 c2x|cons?a:|addrdw cms|
spec 1.2 c2d|buffer|cons
4E
40
40
40
40
586
594
507
366
516
Ready; T=0.01/0.01 15:14:54

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
08/26/2011 02:58:44 PM:

> From: "John P. Hartmann" 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 08/26/2011 02:59 PM
> Subject: Re: printmc truncates lines
> Sent by: CMSTSO Pipelines Discussion List 
>
> But only with ccw command 5a if memory serves.
>
> On 26 August 2011 22:51, Michael Harding  wrote:
> > Define a VAFP printer and point printmc to that.  Max lrecl=32767.
> >
> > --
> > Mike Harding
> > z/VM System Support
> >
> >

Re: [CMS-PIPELINES] printmc truncates lines

2011-08-26 Thread Michael Harding
Define a VAFP printer and point printmc to that.  Max lrecl=32767.

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
08/26/2011 02:11:43 PM:

> From: Paul Gilmartin 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 08/26/2011 02:33 PM
> Subject: printmc truncates lines
> Sent by: CMSTSO Pipelines Discussion List 
>
> I have a print file in my reader with lines over 500 characters
> long (it came from MVS).  I try to reprint it with:
>
>  PIPE READER | APPEND LITERAL | PRINTMC
>
> Lines are truncated at 132 characters (1403) or 204 characters
> (3800).  What device type does RSCS use to put the file in
> the spool?  Can I Define one?  (Or does RSCS manipulate spool
> blocks directly?)
>
> Thanks,
> gil


Re: [CMS-PIPELINES] update an existing disk record in place?

2011-04-25 Thread Michael Harding
I'm not familiar with IOX, but from a hardware standpoint, I don't see how
it cannot be performing a read/update/rewrite cycle even if it hides the
fact.  And not just the record but the entire physical block containing it.

--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
04/25/2011 03:01:42 PM:

> From: Glenn Knickerbocker 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 04/25/2011 03:02 PM
> Subject: update an existing disk record in place?
> Sent by: CMSTSO Pipelines Discussion List 
>
> I'm pretty sure the answer is no, but just in case this is one of those
> things I missed over the years:  I've got an old exec with a bunch of
> IOX UPDATE calls to update fields in existing records in files on disk.
>  Is there any pipelines stage that will do this without having to read
> the unchanged portions of the record from the file first?
>
> ¬R

Re: [CMS-PIPELINES] Looking for a nifty solution

2010-04-06 Thread Michael Harding
Sure!  Use Specs to construct the same callpipe command as a record and
feed it to pipcmd.
--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 323-2070 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
04/06/2010 01:23:34 PM:

> From: "Hughes, Jim" 
> To: CMS-PIPELINES@vm.marist.edu
> Date: 04/06/2010 01:24 PM
> Subject: Looking for a nifty solution
> Sent by: CMSTSO Pipelines Discussion List 
>
> Here is a sample of what I have working:
>
>
>
> /*  */
>
> Signal on novalue
>
> "peekto $data"
>
> Do while rc = 0
>
> Parse var $data $x1 $x2 $x3 .
>
> "callpipe < backup jcl a ",
>
>"| change /$var1/"$x1"/"   ,
>
>"| change /$var2/"$x2"/"   ,
>
>"| change /$var3/"$x3"/",
>
>"|  *: "
>
> "peekto $data"
>
> End
>
>
>
> Return rc*(rc<>12)
>
>
>
> Is there a way to connect the input stage(peekto) directly to the
> callpipe reading the input file and do the variable substitution?
>
>
>
> Just curious
>
>
>
>
>
> 
>
> Jim Hughes
>
> 603-271-5586
>
> "It is fun to do the impossible."
>
>


Re: [CMS-PIPELINES] Remove leading zeros...

2010-02-05 Thread Michael Harding
Rob, I'm surprised.  What if the number is 002004, for example?
--
Mike Harding
z/VM System Support

>
> Sure, if you want and can put it in a spec counter. Otherwise,
> something like this:
>
>  change substr 1;-2 of w1 /0//
>
> Sir Rob the Plumber


Re: [CMS-PIPELINES] DISK minus filemode validation

2009-11-11 Thread Michael Harding
You're both missing the point of Glenn's question.  The "DISK" driver, as
opposed to the "<" driver, normally doesn't complain or present an error if
the input file doesn't exist.  It just presents EOF.  It appears, however,
that it indeed ends with an error (119) if a specific filemode is named and
there's nothing accessed at that filemode.  I've not run into it before,
but would consider it unexpected behavior.  And Glenn, it does look like
state or equivalent test is needed for your situation.  Note that state
even returns a different return code (36) for an empty filemode as opposed
to the 28 for file not found, and maybe that's why DISK's behavior differs.
--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 457-9183 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
11/11/2009 12:57:34 PM:

> From: Paul Gilmartin 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 11/11/2009 12:59 PM
> Subject: Re: DISK minus filemode validation
> Sent by: CMSTSO Pipelines Discussion List 
>
> On 11/11/09 13:46, Frank M. Ramaekers wrote:
> > I get:
> >
> > pipe < dummy dummy * | hole
> > PIPDSR146E File "DUMMY DUMMY *" does not exist.
> > PIPSCA003I ... Issued from stage 1 of pipeline 1.
> > PIPSCA001I ... Running "< dummy dummy *".
> > Ready(00146); T=0.01/0.01 14:45:58
> > pipe < profile exec * | hole
> > Ready; T=0.01/0.01 14:46:06
> >
> > What do you want to do if the file doesn't exist?
> >
> There's a more general underlying question: Is there any way
> to trap such errors, diagnose, and recover?
>
> I don't know the OP's need, but a plausible recovery action
> might be to create the file and initialize it with a header
> record containing a timestamp.
>
> -- gil

Re: [CMS-PIPELINES] Using PIPE to obtain the GMT time from an ntp server?

2009-11-04 Thread Michael Harding
Referring to http://tf.nist.gov/timefreq/service/its.htm

For your basic needs:
Pipe literal  |tcpclient nist1.symmetricom.com 13 oneresponse|xlate a2e|
cons
 55139 09-11-04 21:09:38 00 0 0   0.0 UTC(NIST) *
Ready; T=0.01/0.01 13:09:37

That's a left-coast server.  Depending on where you are you might choose a
wrong-coast one, Or try several ;-)  There's a link on the referenced page
to servers.
--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 457-9183 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
11/03/2009 06:54:49 AM:

> From: Bob Cronin 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 11/03/2009 06:55 AM
> Subject: Re: Using PIPE to obtain the GMT time from an ntp server?
> Sent by: CMSTSO Pipelines Discussion List 
>
> Our VM clocks are so far off that I wouldn't even care if the answer I
got
> from the ntp server was a few seconds off because of latency...
> --
> bc
>
> On Tue, Nov 3, 2009 at 2:21 AM, Rob van der Heij 
wrote:
>
> > On Mon, Nov 2, 2009 at 10:50 PM, Paul Gilmartin 
> > wrote:
> >
> > > Is there a stage that talks to OpenEdition CMS?  (I have _no_
> > > experience with OpenEdition CMS.)  If so, all that's necessary
> > > is to capture the output of "TZ=GMT0 date".
> > >
> > > (In TSO it's easy enough with "address SYSCALL".)
> >
> > This is cheating. Sure, if you assume the operating system has the
> > right time, you just ask there...
> >
> > A pipeline to encode and decode the NTP packets should not be that
> > hard. But even with a pipeline that can handle those you probably
> > still need to follow the protocol that does several requests to
> > eliminate the effect of network latency. This is why the ntp client
> > takes a while to "stabilize" before it adjusts the OS correction
> > factors.
> >
> > Rob
> >


Re: [CMS-PIPELINES] Move files and preserve timestamps

2009-10-21 Thread Michael Harding
I years ago set up a process to mirror the Marist pipelines site, which
might be easily adaptable to your situation.  It uses ftp as transport, and
sets the timestamp of the local files to match the source.
Send me a note off-list if you're interested.
--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 457-9183 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
10/21/2009 02:56:51 PM:

> From: Paul Gilmartin 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 10/21/2009 02:58 PM
> Subject: Re: Move files and preserve timestamps
> Sent by: CMSTSO Pipelines Discussion List 
>
> On 10/21/09 15:47, Avery, Matt wrote:
> > One way of sending files from unix along with metadata is to put the
> > files in a .tar archive.
> >
> Of course.  Or zip.  ARCUTIL undoes zip, I think.
>
> > Unpacking .tar in pipes would be a doddle.
> >
> Not if I have to write it.  Can I steal it?  (What's
> a doddle?)
>
>
> > Only
> > downside is that you would have to deal with all the ASCII/EBCDIC
> > translation, rather than offloading that job to FTP.
> >
> There are stages for that.  DEBLOCK | XLATE.
>
> I used to know a lot of this stuff.
>
> -- gil


Re: [CMS-PIPELINES] STARMSG and CP SEND

2009-10-15 Thread Michael Harding
You don't say, but I'm guessing you first establish yourself as secuser for
EREP.  While the HCP150A is sent to the secuser on behalf of the target, it
isn't SCIF output since it isn't sent to the target's console.  Have you
tried also setting CPCONIO to IUCV?
--
Mike Harding
z/VM System Support

mhard...@us.ibm.com
mike.b.hard...@kp.org
mikehard...@mindless.com
(925) 926-3179 (w)
(925) 457-9183 (c)
IM: VMBearDad (AIM),  mbhcpcvt (Y!)


CMSTSO Pipelines Discussion List  wrote on
10/15/2009 02:04:57 PM:

> From: "Frank M. Ramaekers" 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 10/15/2009 02:05 PM
> Subject: STARMSG and CP SEND
> Sent by: CMSTSO Pipelines Discussion List 
>
> I'm trying to capture the HCP150A message to see if the user issued a VM
> read or a CP read.  I'm using this to END EREP and run reports (on
> another virtual machine after archiving).
>
> My normal process fails when a #CP EXT cause the prompt, but a CP READ:
>
>
> HCPRET8067A ENTER END OR SUMMARY
> HCPCMD001E Unknown CP command: END
> HCPCMD001E Unknown CP command: EXEC
> HCPCMD001E Unknown CP command: PROFILE
> CONNECT= 39:33:06 VIRTCPU= 000:00.34 TOTCPU= 000:00.52
> LOGOFF AT 00:16:00 CDT THURSDAY 10/15/09 BY SYSTEM
>
> This seems to fail every once in a while.
>
> So, experimenting (assume I have done all the SET xMSG IUCV":
>
> "PIPE (endchar ?)",
> "   STARMSG *MSG",
> "|  CONSOLE",
> "|  ZONE 1-8 FIND 0008"||,
> "|  ZONE 9-16 FIND EREP"||,
> "|  LOCATE /HCPQCS150A/",
> "|  PIPESTOP",
> "?",
> "   CP SEND EREP #CP EXT",
> "|  CONSOLE",
> "?",
> "   LITERAL +1:00 WAIT TIME ELAPSED",
> "|  DELAY",
> "|  CONSOLE",
> "|  PIPESTOP"
>
> When I run it, I get:
>
> starmsg
> HCPQCS150A User EREP has issued a VM read
> 0008EREPEREP: HCPRET8067A ENTER END OR SUMMARY
> +1:00 WAIT TIME ELAPSED
> Ready; T=0.01/0.01 15:50:27
>
> I tried *MSGALL, but got into a loop because the STARMSG trapped the
> CONSOLE stage.
>
> Frank M. Ramaekers Jr.
> Systems Programmer   MCP, MCP+I, MCSE & RHCE
> American Income Life Insurance Co.   Phone: (254)761-6649
> 1200 Wooded Acres Dr.Fax:   (254)741-5777
> Waco, Texas  76710
>
>
>
>
>
>
> _
>
> This message contains information which is privileged and
> confidential and is solely for the use of the
>
> intended recipient. If you are not the intended recipient, be aware
> that any review, disclosure,
>
> copying, distribution, or use of the contents of this message is
> strictly prohibited. If you have
>
> received this in error, please destroy it immediately and notify us
> at privacy...@ailife.com.

Re: [CMS-PIPELINES] reversing *parts* of a record

2009-08-25 Thread Michael Harding
While all-pipes solutions are usually elegant and always inherently cool,
either Bob's or the Piper's could be a challenge to build dynamically.  I'd
probably use one or the other - or something similar - for a fixed case,
but I think Shimon's search for a generalized solution would be more easily
addressed by a Rexx stage and wouldn't suffer that much of a performance
penalty.

--
Mike Harding

CMSTSO Pipelines Discussion List  wrote on
08/25/2009 07:40:44 AM:

> From: Bob Cronin 
> To: CMS-PIPELINES@VM.MARIST.EDU
> Date: 08/25/2009 07:41 AM
> Subject: Re: reversing *parts* of a record
> Sent by: CMSTSO Pipelines Discussion List 
>
> Couldn't you use Specs to do this? Assign those parts of the record
> that need to be reversed to a variable and use "print reverse(var)" to
> build the output record?
>
> For example
>
> PIPE Strliteral /abcdefg 12345 hijklmn 6789/
>   | Specs a: w1 . b: w3 . print reverse(a) 1 w2 nw print reverse(b) nw w4
nw
>   | Console
>
> produces:
>
> gfedcba 12345 nmlkjih 6789
> --
> bc
>
> On Tue, Aug 25, 2009 at 7:17 AM, John P. Hartmann
wrote:
> > 3WAY gets you one range of a record.  You'll need two, the second on
> > the tertiary output from the first.
> >
> > |w1: 3way w4
> > |g1: gather
> > \w1:
> > |reverse
> > |g1:
> > \w1:
> > |w2: 3way w-2
> > |g1:
> > \w2:
> > |reverse
> > |g1:
> > \w2:
> > |g1:
> >
> >   j.
> >
> > 2009/8/25 Shimon Lebowitz :
> >> I am trying to deal with a problem apparently created for me by
> Mr. Gates & Co.
> >>
> >> I need to send files from CMS to end users on PCs, where the
> >> files contain data which represents Hebrew characters. I gave
> >> SMTP a translation table which converts the EBCDIC representation
> >> of Hebrew to the ASCII used by Windows, but the PC is a smart alec,
> >> and also reverses the character order, since Hebrew reads right to
left.
> >>
> >> So, if I have input records like this on CMS:
> >>
> >> 2008   12987   65084  abcdefgh    78346  45239  tuvwxyz    873468
> >> 2009       31       836     ijklmno   169827   8373      mnop
34902
> >>
> >> (Note: the letters in the actual record will be Hebrew! I only used
> >> English to prevent the confusion that happens when the order gets
> >> reversed. And besides, how many of you have Hebrew fonts?).
> >>
> >> If I SendFile a file of those records to a MS-Win system,
> >> the characters will be displayed on the screen as hgfedcba, zyxwvut,
> >> etc. In order to have the data normal when it arrives, I need
> >> to reverse the field which contains the Hebrew text, but obviously NOT
> >> the other parts of the record, which would destroy the numeric values.
> >>
> >> What I think would be my favorite solution would be for the REVERSE
> >> stage to accept inputranges, as the XLATE stage does. That would be
great!
> >> A simple ... | REVERSE 22-31 48-56 | ...  would solve my problem
> >> easily and elegantly. But... REVERSE has no ranges. :-(
> >>
> >> Since the EXEC I am writing must deal with many different
> >> files, and will receive external arguments defining the positions
> >> of the Hebrew fields, I need a generalized solution. I tried something
> >> with a particular case, where I knew the positions (only one
> >> Hebrew field 5-24) and the record length (fixed 32):
> >> ...
> >> 'F1: FANOUT |',
> >> 'F2: FANINANY |',
> >>    'JOIN 1 |',
> >>    'SPECS 1-32 1 33-* 5 |',
> >>    '>'  OUTPUTID,
> >> '? F1: |',
> >>    'SPECS 5-24 1 |',
> >>    'REVERSE |',
> >> 'F2:'
> >>
> >> How would I generalize this? And is there a better way?
> >>
> >> Thanks!
> >> Shimon
> >>
> >