如下SQLSERVER的存储过程要需要如何修改? 10
CREATEPROCEDUREpressure_istrue@comp_namevarchar(50)@BoolValuevarchar(5)@ReturnValueva...
CREATE PROCEDURE pressure_istrue
@comp_name varchar(50)
@BoolValue varchar(5)
@ReturnValue varchar(5)
AS
BEGIN
SELECT @BoolValue =suspend_status FROM Pressure_Stauts WHERE comp_name=@comp_name
IF @BoolValue='True'
@ReturnValue='True'
ELSE
@ReturnValue='False'
END
RETURN @ReturnValue
GO 展开
@comp_name varchar(50)
@BoolValue varchar(5)
@ReturnValue varchar(5)
AS
BEGIN
SELECT @BoolValue =suspend_status FROM Pressure_Stauts WHERE comp_name=@comp_name
IF @BoolValue='True'
@ReturnValue='True'
ELSE
@ReturnValue='False'
END
RETURN @ReturnValue
GO 展开
1个回答
展开全部
CREATE PROCEDURE pressure_istrue
@comp_name varchar(50),
@BoolValue varchar(5)
AS
BEGIN
declare @ReturnValue varchar(5)='True'
SELECT @BoolValue =suspend_status FROM Pressure_Stauts WHERE comp_name=@comp_name
IF @BoolValue<>'True'
set @ReturnValue='False'
RETURN @ReturnValue
GO
@comp_name varchar(50),
@BoolValue varchar(5)
AS
BEGIN
declare @ReturnValue varchar(5)='True'
SELECT @BoolValue =suspend_status FROM Pressure_Stauts WHERE comp_name=@comp_name
IF @BoolValue<>'True'
set @ReturnValue='False'
RETURN @ReturnValue
GO
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询