I wan’t to display columns based on conditions/parameters
what i want is
if(@SelectFlag==true)
select name,Address,salary,CreatedBy from employee
else (@UpdateFlag==true)
select name,Address,salary from employee
-- in this case i don't require the column "CreatedBy"
How can i make a query or stored procedure looking at the above circumstances..
Thanks & regards..
Use single
=and1instead oftrue.