0

I have a string '1523987654' and I need to check if only have numbers.

First I had used ISNUMERIC, but it dosen't worked with '.'

SELECT CASE WHEN 
ISNUMERIC('.') = 1
 THEN 1 ELSE 
0
 END

I had try with LIKE, but without sucess

SELECT CASE WHEN 
'1523987654'  LIKE '[0-9]'
 THEN 1 ELSE 0 END

Any suggestions ?

Agustin Meriles
  • 4,866
  • 3
  • 29
  • 44
Rui Soares
  • 19
  • 2
  • 3

0 Answers0