Hi @Sherlan Emmanuel Burgonia
You could use RIGHT or SUBSTRING functions to ignore first three digits. Check the sample below:
CREATE TABLE #TABLE(ID VARCHAR(20))
INSERT INTO #TABLE VALUES
('00160885'),('00260885'),('00133263'),('00233263')
SELECT ID
FROM #TABLE
WHERE RIGHT(ID,LEN(ID)-3) = 60885
SELECT ID
FROM #TABLE
WHERE SUBSTRING(ID,4,LEN(ID)) = 60885
Best regards,
LiHong
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our Documentation to enable e-mail notifications if you want to receive the related email notification for this thread.