declare @p1 intset @p1=1exec sp_prepexec @p1 output,N'@contact_id int',N'Select Count(*) as persons from Person.Contact Where contactid = @contact_id',@contact_id=541select @p1