I have stored procedure, using this Sp am inserting data into employee table and am passing values as input parameters like ,
create procedure sp_inputvalues
@ename varchar(50),
@enum int,
@address varchar(100),
@sal int
as
begin
insert into employee(ename,enum,address,salary)values(@ename,@enum,@address,@sal)
end
To execute the Sp ,
exec sp_inputvalues 'venkat',1252,'nrl',20000
but now my requirement is i need to pass the input values in random order like,
exec sp_inputvalues 1252,'venkat','nrl',20000
if I pass as above format the stored procedure should work and the stored procedure should be remain same.
You need to specify the names of the parameters