declare @c varchar(100)
set @c = '1,2,3'
if exists(select * from DyDir where charindex(cast(DyJD as varchar),@c)>0)
print 1111
else
print 2222
declare @c varchar(100)
set @c = '1,2,3'
if exists(select * from DyDir where charindex(cast(DyJD as varchar),@c)>0)
print 1111
else
print 2222