我有一个存储过程:
/* data from the Users table*/
create procedure sp_recovery_name_Users
(
@i_id_cod int,
@u_name varchar(50) = null out
)
AS
select
@u_name = name
from
User
where
cod = @i_id_cuenta
if (@@rowcount != 1 OR @@error != 0)
return 8
return 0
go
如何将存储过程的列传递给临时表?
/*not working*/
create table #temp
(
t_nombre varchar(50)
)
insert into #temp
exec sp_recovery_name_Users