i have a stored procedure
Create PROCEDURE abc @sRemovePreviouslySelectedWhereClause nvarchar(max) AS BEGIN SELECT * FROM table WHERE nId
You will need to use Dynamic sql for such kind of queries.
first construct the query and
SET @sql = 'select * from table where nId not in (' + @sRemovePreviouslySelectedWhereClause+ ')'
then use EXEC(@sql) to run the query.
EXEC(@sql)