ROLLBACK TRAN
return
END
set @iSuccess = -3
update rb_UserRoles set RoleID=@RoleID where UserID=@UserID
IF @@ERROR <> 0
BEGIN
ROLLBACK TRAN
return
END
COMMIT TRAN
set @iSuccess = 1
GO
2. 条件查询语句:
条件查询直接放在SQL中判断
CREATE PROCEDURE IR_SysAuthorization_GetAllSysAuthorization
(
@Type int,
@UserID varchar(20)
)
AS
declare @strsql varchar(1500) --临时sql语句
declare @strwhere varchar(1000) --临时sql的条件语句
set @strsql = ''
延伸阅读
文章来源于领测软件测试网 https://www.ltesting.net/