Hi
I want to find out the exact numeric part prom the string. I am using Patindex
but the problem is if the Number exists at the very Ist place, it does not work
select patindex('%[^0-9]12[^0-9]%','12,13127,12') returns 0
select patindex('%[^0-9]12[^0-9]%',' 12,13127,12') returns 1 (The extra space at the begining )
select patindex('%[^0-9]12[^0-9]%','12,13127,12 ') returns 9 (The extra space at the end  
where as i need 1 with select patindex('%[^0-9]12[^0-9]%','12,13127,12')
Anyone Please