I have a Mysql query. I want to filter only integer result.
My query is-
SELECT * FROM table as p WHERE p.test between 0 AND 999
But result comes this-
747
748
749
FO4001
FO4002
750
751
I want to ask two things-
1)Is there any way to exclude below result-
FO4001
FO4002
2)Why are these coming in the result?
Try this one, use
REGEXPto test if the value is all numeric.SQLFiddle Demo