Here is an example of input value:
00080a7a00
and the expected output of this input:
80a7
To get the expected output i tried the following query:
set @ttt='00080a7a00'
select SUBSTRING(@ttt,PATINDEX('%[1-9]%',@ttt),LEN(@ttt))
And i am getting this output:
80a7a00
So i am looking for the correct query to have the expected output.