RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Browse Expressions by Category

107 regular expressions found in this category!

Expressions in category: Numbers

Change page:   |    Displaying page 3 of 6 pages; Items 41 to 60
Title Test Details Pattern Title
Expression
^[0-9]*(\.)?[0-9]+$
Description
it will check for the +ve decimal numbers
Matches
1 | 123 | 132.132
Non-Matches
1.2.2 | -123
Author Rating: The rating for this expression. himraj love
Title Test Details Pattern Title
Expression
^(\-)?1000([.][0]{1,3})?$|^(\-)?\d{1,3}$|^(\-)?\d{1,3}([.]\d{1,3})$|^(\-)?([.]\d{1,3})$
Description
allows positive and negative none-to-3-decimal values between -1000.000 and 1000.000
Matches
123.456 | -0.125 | -1000.000
Non-Matches
123.4567 | -0.1b5 | -1000.001
Author Rating: The rating for this expression. gregg durishan
Title Test Details Pattern Title
Expression
^(\d|,)*\d*$
Description
matches 0 and all positive integers only. will accept comma formatting only.
Matches
1234 | 1,234 | 1,234,567
Non-Matches
1234.0 | -1234 | $1234
Author Rating: The rating for this expression. Donald Schneider
Title Test Details Pattern Title
Expression
^[0-9]+$
Description
Validate a string to see if it contains a number / integer
Matches
1234567890 | 1234567890 | 1234567890
Non-Matches
http://none | http://none | http://none
Author Rating: The rating for this expression. Mr M
Title Test Details Pattern Title
Expression
(^(\+?\-? *[0-9]+)([,0-9 ]*)([0-9 ])*$)|(^ *$)
Description
This is my basic phone number verification. it allows a + - , signs digits, spaces and blank entry
Matches
+0335456 545 545 | -5465 545 | 5456465 5454,545
Non-Matches
fsd54df 54
Author Rating: The rating for this expression. Vitaly Kompot
Title Test Details Pattern Title
Expression
^\$?([0-9]{1,3},([0-9]{3},)*[0-9]{3}|[0-9]+)(.[0-9][0-9])?$
Description
Matches currency input with or without commas.
Matches
$3,023,123.34 | 9,876,453 | 123456.78
Non-Matches
4,33,234.34 | $1.234 | abc
Author Rating: The rating for this expression. Brian Orrell
Title Test Details Pattern Title
Expression
^[+-]?([0-9]*\.?[0-9]+|[0-9]+\.?[0-9]*)([eE][+-]?[0-9]+)?$
Description
A regular expression that matches numbers. Integers or decimal numbers with or without the exponential form.
Matches
23 | -17.e23 | +.23e+2
Non-Matches
+.e2 | 23.17.5 | 10e2.0
Author Rating: The rating for this expression. Erik Pettersson
Title Test Details Pattern Title
Expression
^[-+]?[0-9]\d{0,2}(\.\d{1,2})?%?$
Description
Required and regular expression validator. For supporting -999.99 to +999.99 . Positive and Negative integer/ decimal validations. Percentage sign is also supported. Will not allow empty strings. Can increase/decrease the range as you need.
Matches
12.3 | 123 | -123.45
Non-Matches
- | 10.1234 | -1234
Author Rating: Not yet rated. Error Reporter
Title Test Details Pattern Title
Expression
^\-?\(?([0-9]{0,3}(\,?[0-9]{3})*(\.?[0-9]*))\)?$
Description
Match a positive or negative decimal value with any precision and scale. Allows for left-padded zeroes, commas as group separator, negative sign (-) or parenthesis to indicate negative number.
Matches
0.123 | (1234.123) | -01,200
Non-Matches
2.3.123 | 1,23.45
Author Rating: Not yet rated. Rich Franzmeier
Title Test Details Pattern Title
Expression
^(?!\u00a2) #Don't allow cent symbol \p{Sc}? #optional unicode currency symbols (?!0,?\d) #don't allow leading zero if 1 or more unit (?:\d{1,3} # 1 to 3 digits (?:([, .])\d{3})? # if there is a separator it must be followed by 3 digits (?:\1\d{3})* # if the is more than two groups the same separtor must but used, it must be followed by 3 digits |(?:\d+)) # more than 3 digit with no comma separator ((?!\1)[,.]\d{2})?$ # option cents
Description
Internationally capable currency formats. It is NOT local aware. Should be modify for local specific validations. More detail at http://blogs.regexadvice.com/mash/archive/2004/06/08/1246.aspx
Matches
$9,876,543.21 | €9 876 543,21 | €9.876.543,21
Non-Matches
9.876.543.21 | 9,876,543,21 | 9 876 543 21
Author Rating: Not yet rated. Michael Ash
Title Test Details Pattern Title
Expression
^(\d{1,3}'(\d{3}')*\d{3}(\.\d{1,3})?|\d{1,3}(\.\d{3})?)$
Description
This regex match numeric data in the following format: thousands are separated by (') apostrophe, decimal places are separated by dot (.) Maximum three decimal places are not required. It's easy to change to other separators as well.
Matches
1'235.140 | 1'222'333.120 | 456
Non-Matches
1234.500 | 78'45.123 | 123,0012
Author Rating: Not yet rated. Dalibor Kalna
Title Test Details Pattern Title
Expression
\$[0-9]?[0-9]?[0-9]?((\,[0-9][0-9][0-9])*)?(\.[0-9][0-9])?$
Description
Matches
$28,009,987.88 | $23,099.05 | $.88
Non-Matches
$234,5.99
Author Rating: Not yet rated. yahnique barrett
Title Test Details Pattern Title
Expression
^\$?(\d{1,3}(\,\d{3})*|(\d+))(\.\d{0,2})?$
Description
From Author: DON'T USE THIS ONE. FIND MY OTHER ONE THAT BLOCKS LEADING ZEROS. My site also couldn't swallow the \d, so I switched to numeric ranges and it worked fine. KEYWORDS Currency Money Dollar
Matches
$0,234.50 | 0234.5 | 0,234.
Non-Matches
$1,23,50 | $123.123
Author Rating: Not yet rated. Tom Persing
Title Test Details Pattern Title
Expression
^[1-9]{1}$|^[1-4]{1}[0-9]{1}$|^50$
Description
Match any number between 1 and 50, no characters, no empty sets, and not zero. Match numbers greater than 1 and less than 51, no spaces, no characters.
Matches
1 | 23 | 50
Non-Matches
0 | 111 | xyz
Author Rating: Not yet rated. Michael Gaertner
Title Test Details Pattern Title
Expression
^([1-9]|[1-9]\d|100)$
Description
This pattern matches whole numbers 1-100.
Matches
1 | 50 | 100
Non-Matches
0 | .5 | 101
Author Rating: Not yet rated. Manny Ruiz
Title Test Details Pattern Title
Expression
^\$[+-]?([0-9]+|[0-9]{1,3}(,[0-9]{3})*)(\.[0-9]{1,2})?$
Description
This expression is little tricky since the $ sign is includeded in the expression itself. So whenever you want to make use of the expression be sure to prepend $ sign to the value if it's not present.
Matches
$-1 | $-1.0 | $1,234.42
Non-Matches
anything that doesn't start with $ | $.13 | $2.
Author Rating: Not yet rated. Chandrasing Patil
Title Test Details Pattern Title
Expression
(^-\d*\.?\d*[1-9]+\d*$)|(^-[1-9]+\d*\.\d*$)
Description
Accepts only negative decimal values. Zero and positive numbers are non-matching. Allows zeros after last non-zero numeric value after decimal place for significant digits.
Matches
-0.050 | -5.000 | -5
Non-Matches
0 | 0.0 | .0
Author Rating: Not yet rated. Bri Gipson
Title Test Details Pattern Title
Expression
^\d*[0-9](|.\d*[0-9]|,\d*[0-9])?$
Description
This is permit all decimal number, exclude all alphanumeric caracter
Matches
123456.123456 | 123456,123456 | 123456
Non-Matches
123a.123 | 123a,123 | a
Author Rating: Not yet rated. Hugues Gauthier
Title Test Details Pattern Title
Expression
(^(((\d)|(\d\d)|(\d\d\d))(\xA0|\x20))*((\d)|(\d\d)|(\d\d\d))([,.]\d*)?$)
Description
For who use a space as thousands separator like french, deutsch ....
Matches
1 200 | 1 241 588.14567 | 123
Non-Matches
az | 1254.456 | 1234
Author Rating: Not yet rated. krest krest
Title Test Details Pattern Title
Expression
(^[0]{1}$|^[-]?[1-9]{1}\d*$)
Description
This is a regular expression I used to validate negative and positive WHOLE numbers, including 0.
Matches
0 | 123 | -123
Non-Matches
001 | -012 | -002
Author Rating: Not yet rated. Les Portugal
Change page:   |    Displaying page 3 of 6 pages; Items 41 to 60

Copyright © 2001-2024, RegexAdvice.com | ASP.NET Tutorials