use OU:
select * from yourTable
where @test = '' OR Agent = @test
if @
test vindo com valor nulo (em vez de '' ), você deve usar:select * from yourTable
where @test is null OR Agent = @test
select * from yourTable
where @test = '' OR Agent = @test
test vindo com valor nulo (em vez de '' ), você deve usar:select * from yourTable
where @test is null OR Agent = @test