-
( * dbo.sysobjects, [id] = object_id (N'dbo.t ') objectproperty (id, N'IsUserTable') = 1)
drop table dbo.t
-
create table dbo.t(c varchar (10) null)
set nocount
-
dbo.t(c) ('1')
dbo.t(c) ('2')
dbo.t(c) ('3')
dbo.t(c) ('10 ')
dbo.t(c) ('11')
dbo.t(c) ('aaaa')
dbo.t(c) ('aaab')
dbo.t(c) ('b')
dbo.t(c) ('ba')
dbo.t(c) ('ba')
-
c dbo.t
, isnumeric (c) = 1, 0 else 1 end,
case, isnumeric (c) = 1, cast (c as int) else 0 end,
c
source
share