Using Microsoft SQL Server 2012 - 11.0.5058.0 (X64) Express Edition (64-bit) on Windows NT 6.1 (Build 7601: Service Pack 1) (Hypervisor)
with that creation/fill script :
CREATE TABLE tbl (col CHAR (32) )
insert into tbl values ('test')
Those kind of statements :
declare @var varchar(32) = 'test'
delete from tbl where col like @var
or
delete from tbl where col like 'test'
actually delete the line but why this one :
declare @nvar nvarchar(32) = 'test'
delete from tbl where col like @nvar
do not delete the line ?