日期:2014-05-18  浏览次数:20446 次

存储过程??
alter   procedure   sp_yh
@uid     varchar(10),
@pwd     varchar(20),
@qx       int
as
insert   into   yh(用户名,密码,权限)  
select   *   from   yh   where   用户名=@uid   and   密码=@pwd   and   权限=@qx

这是我写的存储过程
exec   sp_yh   '22 ', ' ', ' '
我执行时候,,为什么不能插入记录哦。。


------解决方案--------------------
執行的時候有什麼錯誤提示沒有?

alter procedure sp_yh
@uid varchar(10),
@pwd varchar(20),
@qx int
as
insert into yh(用户名,密码,权限)
select 用户名,密码,权限 from yh where 用户名=@uid and 密码=@pwd and 权限=@qx
GO
--調用
exec sp_yh '22 ', ' ',0