Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VAL() type of function?
Message
From
04/09/2003 09:59:02
 
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Miscellaneous
Thread ID:
00825781
Message ID:
00826007
Views:
27
Hi Stephen,

try
DECLARE @myCol varchar(15)

SET @myCol = 'FAB-767LUN'

SELECT CONVERT(INT,SUBSTRING(LEFT(@myCol,PATINDEX('%[1-9][A-Z]%',@myCol+'A')),PATINDEX('%-[0-9]%',@myCol)+1,15)) myValue
Fabio
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform