RE: Struts Validator 4 digit numeric

2002-11-27 Thread Jarnot Voytek Contr AU HQ/SC
The * is a repetition operator, as the error said.  You basically asked for
'exactly four' and 'zero or more' digits with the {4}* ... obviously that
doesn't make sense.

-Original Message-
From: Greg Dunn [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 9:28 AM
To: Struts Users Mailing List
Subject: RE: Struts Validator 4 digit numeric


Yes, I did try that, it causes the same  "Nested repetitions *?+ in
expression" error.  However removing the * seems to have fixed things.  I
thought the * had to be in the mask expression in validation.xml because it
was in all the examples I read in the docs.  Where can I find a good Reg.
Expression tutorial?  Thanks.

Greg



-Original Message-
From: Jarnot Voytek Contr AU HQ/SC [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 9:14 AM
To: 'Struts Users Mailing List'
Subject: RE: Struts Validator 4 digit numeric


Did you try ^\d{4}$
Why do you include the * in your regexp - I think that's what's breaking it.

--
Voytek Jarnot


-Original Message-
From: Greg Dunn [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 9:07 AM
To: Struts Users Mailing List
Subject: Struts Validator 4 digit numeric


I'm trying to use Struts Validator to validate a 4 digit numeric using a
mask:


   
   
   mask
   ^[0-9]{4}*$
   


Which causes:

"Invalid expression: ^[0-9]{4}*$ Nested repetitions *?+ in expression"

The expression ^[0-9]^4*$ causes no exception but it throws out '' as
not
valid.  (Obviously I have work to do on regular expressions.)  Any
assistance is appreciated.


Greg


--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>




--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>




RE: Struts Validator 4 digit numeric

2002-11-27 Thread Jason Rosen
One of the best regex resources are the PERL man-pages:
http://www.perldoc.com/perl5.8.0/pod/perlre.html

Jason

-Original Message-
From: Greg Dunn [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 7:28 AM
To: Struts Users Mailing List
Subject: RE: Struts Validator 4 digit numeric


Yes, I did try that, it causes the same  "Nested repetitions *?+ in
expression" error.  However removing the * seems to have fixed things.  I
thought the * had to be in the mask expression in validation.xml because it
was in all the examples I read in the docs.  Where can I find a good Reg.
Expression tutorial?  Thanks.

Greg



-Original Message-
From: Jarnot Voytek Contr AU HQ/SC [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 9:14 AM
To: 'Struts Users Mailing List'
Subject: RE: Struts Validator 4 digit numeric


Did you try ^\d{4}$
Why do you include the * in your regexp - I think that's what's breaking it.

--
Voytek Jarnot


-Original Message-
From: Greg Dunn [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 9:07 AM
To: Struts Users Mailing List
Subject: Struts Validator 4 digit numeric


I'm trying to use Struts Validator to validate a 4 digit numeric using a
mask:


   
   
   mask
   ^[0-9]{4}*$
   


Which causes:

"Invalid expression: ^[0-9]{4}*$ Nested repetitions *?+ in expression"

The expression ^[0-9]^4*$ causes no exception but it throws out '' as
not
valid.  (Obviously I have work to do on regular expressions.)  Any
assistance is appreciated.


Greg


--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>




--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>




RE: Struts Validator 4 digit numeric

2002-11-27 Thread Greg Dunn
Yes, I did try that, it causes the same  "Nested repetitions *?+ in
expression" error.  However removing the * seems to have fixed things.  I
thought the * had to be in the mask expression in validation.xml because it
was in all the examples I read in the docs.  Where can I find a good Reg.
Expression tutorial?  Thanks.

Greg



-Original Message-
From: Jarnot Voytek Contr AU HQ/SC [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 9:14 AM
To: 'Struts Users Mailing List'
Subject: RE: Struts Validator 4 digit numeric


Did you try ^\d{4}$
Why do you include the * in your regexp - I think that's what's breaking it.

--
Voytek Jarnot


-Original Message-
From: Greg Dunn [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 9:07 AM
To: Struts Users Mailing List
Subject: Struts Validator 4 digit numeric


I'm trying to use Struts Validator to validate a 4 digit numeric using a
mask:


   
   
   mask
   ^[0-9]{4}*$
   


Which causes:

"Invalid expression: ^[0-9]{4}*$ Nested repetitions *?+ in expression"

The expression ^[0-9]^4*$ causes no exception but it throws out '' as
not
valid.  (Obviously I have work to do on regular expressions.)  Any
assistance is appreciated.


Greg


--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>




--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>




RE: Struts Validator 4 digit numeric

2002-11-27 Thread Jarnot Voytek Contr AU HQ/SC
Did you try ^\d{4}$ 
Why do you include the * in your regexp - I think that's what's breaking it.

--
Voytek Jarnot


-Original Message-
From: Greg Dunn [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 27, 2002 9:07 AM
To: Struts Users Mailing List
Subject: Struts Validator 4 digit numeric


I'm trying to use Struts Validator to validate a 4 digit numeric using a
mask:


   
   
   mask
   ^[0-9]{4}*$
   


Which causes:

"Invalid expression: ^[0-9]{4}*$ Nested repetitions *?+ in expression"

The expression ^[0-9]^4*$ causes no exception but it throws out '' as
not
valid.  (Obviously I have work to do on regular expressions.)  Any
assistance is appreciated.


Greg


--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>




Struts Validator 4 digit numeric

2002-11-27 Thread Greg Dunn
I'm trying to use Struts Validator to validate a 4 digit numeric using a
mask:


   
   
   mask
   ^[0-9]{4}*$
   


Which causes:

"Invalid expression: ^[0-9]{4}*$ Nested repetitions *?+ in expression"

The expression ^[0-9]^4*$ causes no exception but it throws out '' as
not
valid.  (Obviously I have work to do on regular expressions.)  Any
assistance is appreciated.


Greg


--
To unsubscribe, e-mail:   
For additional commands, e-mail: