今天通一上午的学习,和下午的复习,让我们学会了一些新的知识。比如:
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
alter procedure [dbo].[CheckUser]
CREATE PROCEDURE <Procedure_Name, sysname, ProcedureName>
-- Add the parameters for the stored procedure here
@userid varchar(6),
@password varchar(16),
@power int output,
@lock bit output
as
begin
set nocount on;
declare @count int
select @count=count(*) from Users u where u.uid=@userid and u.[password]=@password
select @power=[power],@lock=lock from Users u where u.uid=@userid and u.[password]=@password
if(@count=1)
return "注册成功"
else
return "注册失败"
End
等。