Maybe you need it!!!
Wednesday, 26 February 2014
[MySQL] - Regular Expressions - How to check a decimal number
To check if the field value is a decimal number, you can use the following expresion
REGEXP '^[[:digit:]]+\\.{0,1}[[:digit:]]*$'
Example:
select '3.222' REGEXP '^[[:digit:]]+\\.{0,1}[[:digit:]]*$' as prueba;
Newer Posts
Older Posts
Home
Subscribe to:
Posts (Atom)