Dynamically changing Column Name
@Status varchar(50)=null
select
x.name,
--x.Status => this status column name should change according to parameter passed
(case when @status='Success' then x.status as 'SuccessCount'
else 'FailCount' end)
from tblabc x
how to proceed...?
thanks in advance...,