高手请进来写一条SQL存储过程语句!

来源:百度知道 编辑:UC知道 时间:2024/05/21 06:26:41
NewsSql = "Select * from News Where ClassID='" & RsClassObj("ClassID") & "' and DelTF=0 and AuditTF=1 order by AddDate desc,id desc

是用存储过程怎么写??我用ASP与MSSQL数据库在ASP怎么把过程调出来,谢谢解答

存储过程大概是
create proc GetSelect
@classid varchar(50)
begin
select * from News Where ClassID=@classid and DelTF=0 and AuditTF=1 order by AddDate desc,id desc
end

调用跟原来的使用方法一样的

了解一下存储过程吧