Pattern Help

Richard Sheehan sheerich@isu.edu
Thu, 29 Nov 2001 12:36:38 -0700


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