districtid 2901 2906 2907
output 01 06 07
select right(convert(varchar,districtid) ,2) FROM tablename
SELECT districtid % 100 AS id FROM tablename
SELECT SUBSTRING(CAST(districtid AS VARCHAR),3,4) AS Output FROM TableName
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)