Pattern Help
Richard Sheehan
sheerich@isu.edu
Thu, 29 Nov 2001 13:46:32 -0700
OK,
define t1 char*6 = "T12345"
define t1a char*3 = "OK" if (matchpattern(t1,"^#####") and &
not matchpattern(t1,"(M|C|#)#####")) else "BAD"
rep t1 t1a
go
> "Olson, Ingemar" wrote:
>
> Sorry guys. You didn't do all the test cases.
> (eg)
>
> define t1 char*6 = "ABCDEF"
> define t1a char*3 = "OK" if not matchpattern(t1,"(M|C|#)#####") else
> "BAD"
> rep t1 t1a
> go
>
> T1 T1A
>
> ABCDEF OK
>
> Ingemar Olson
>
> -----Original Message-----
> From: Richard Sheehan [mailto:sheerich@isu.edu]
> Sent: November 29, 2001 11:37
> To: Pickering, John (NORBORD)
> Cc: Sarah Moore; powerh-l@lists.swau.edu
> Subject: Re: Pattern Help
>
> can cle
>
> define t1 char*6 = "123456"
> define t1a char*3 = "OK" if not matchpattern(t1,"(M|C|#)#####") else
> "BAD"
>
> define t2 char*6 = "A23456"
> define t2a char*3 = "OK" if not matchpattern(t2,"(M|C|#)#####") else
> "BAD"
>
> define t3 char*6 = "M23456"
> define t3a char*3 = "OK" if not matchpattern(t3,"(M|C|#)#####") else
> "BAD"
>
> define t4 char*6 = "C23456"
> define t4a char*3 = "OK" if not matchpattern(t4,"(M|C|#)#####") else
> "BAD"
>
> rep t1 t1a skip &
> t2 t2a skip &
> t3 t3a skip &
> t4 t4a skip
> go
>
> 11/29/2001 PLANT MANAGEMENT DATABASE
> PAGE 1
>
> T1 T1A
>
> T2 T2A
>
> T3 T3A
>
> T4 T4A
>
> 123456 BAD
> A23456 OK
> M23456 BAD
> C23456 BAD
>
> "Pickering, John (NORBORD)" wrote:
> >
> > Even after I corrected my obvious type it doesn't work :-(
> >
> > Q U I Z (PowerHouse 8.19.C4)
> > Copyright 1999 COGNOS INCORPORATED
> > Norbord Industries Inc.
> >
> > > def d-test char*6 = parm
> > > edit d-test pattern "\(M|C|\^)#####"
> > ^^^^^^^^^^^^^^^^
> > *W* An invalid pattern was used to edit an execution-time parameter.
>
> > >
> >
> > > -----Original Message-----
> > > From: Pickering, John (NORBORD) [SMTP:PICKERIJ@norbord.com]
> > > Sent: Thursday, November 29, 2001 2:04 PM
> > > To: 'Richard Sheehan'; Sarah Moore; powerh-l@lists.swau.edu
> > > Subject: RE: Pattern Help
> > >
> > > How about "\(M|C||^)#####"
> > >
> > > Yours will allow 6 digits
> > >
> > <snip>
>
> --
> Richard Sheehan,
> Administrative Systems - IT Programmer Analyst
> Idaho State University Computing & Communications
> Campus Box 8037, Pocatello, ID 83209-8037
> Phone: 208.282.3861 - Fax: 208.282.3673
> Email: sheerich@isu.edu
>
> = = = = = = = = = = = = = = = = = = = = = = = = = = = =
> Mailing list: powerh-l@lists.swau.edu
> Subscribe: "subscribe" in message body to
> powerh-l-request@lists.swau.edu
> Unsubscribe: "unsubscribe" in message body to
> powerh-l-request@lists.swau.edu
> http://lists.swau.edu/mailman/listinfo/powerh-l
> This list is closed, thus to post to the list you must be a
> subscriber.
--
Richard Sheehan,
Administrative Systems - IT Programmer Analyst
Idaho State University Computing & Communications
Campus Box 8037, Pocatello, ID 83209-8037
Phone: 208.282.3861 - Fax: 208.282.3673
Email: sheerich@isu.edu