Sunday, December 28, 2014

Get Revision Number From A Varchar Column


Select Order_Number
,ISNULL(nullif(REVERSE(SUBSTRING(REVERSE(Order_Number),0,CHARINDEX('R',REVERSE(Order_Number)))),''),0)


No comments:

Post a Comment