OUTPUT怎么样处理NTEXT数据类型
///表已经存在了;
CREATE PROCEDURE GetNewsInfo
(
@Id BIGINT ,
@Title VARCHAR(100) OUTPUT,
@Content ntext OUTPUT //就这句有问题,要怎么该,请高手帮忙哦!
)
AS
IF EXISTS
(
SELECT * FROM NewsInfo
WHERE Id=@Id
)
RETURN 0
ElSE
begin
SELECT
@Title=Title,@Content=Content
FROM NewsInfo
WHERE Id=@Id
RETURN 1
end
GO
------解决方案-----------------------TRY it
CREATE PROCEDURE GetNewsInfo
(
@Id BIGINT ,
@Title VARCHAR(100) OUTPUT,
@Content varbinary OUTPUT //就这句有问题,要怎么该,请高手帮忙哦!
)
AS
IF EXISTS
(
SELECT * FROM NewsInfo
WHERE Id=@Id
)
RETURN 0
ElSE
begin
SELECT
@Title=Title,@Content=Content
FROM NewsInfo
WHERE Id=@Id
RETURN 1
end
GO