Prima oara ruleaza asta ..
Apoi ruleaza asta
Succes !
- Cod:
USE [GunzDB]
GO
/****** Object: StoredProcedure [dbo].[spGetLoginInfo] Script Date: 08/09/2009 07:13:25 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/* LoginInfo 얻어옴 */
ALTER PROC [dbo].[spGetLoginInfo]
@UserID varchar(20)
AS
SET NOCOUNT ON
DECLARE @IP VARCHAR(40)
SELECT @IP=LastIP FROM LOGIN(NOLOCK) WHERE UserID=@UserID
DECLARE @IP2 VARCHAR(40)
SELECT @IP2=IP FROM ipbans(NOLOCK) WHERE IP=@IP
IF @IP = @IP2
BEGIN
RETURN 1 -- Wrong Password
END
SELECT AID, UserID, Password FROM Login(nolock) WHERE UserID = @UserID
Apoi ruleaza asta
- Cod:
USE [GunzDB]
GO
/****** Object: Table [dbo].[ipbans] Script Date: 08/09/2009 07:22:30 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_PADDING ON
GO
CREATE TABLE [dbo].[ipbans](
[UserID] [varchar](20) NULL,
[IP] [varchar](20) NULL
) ON [PRIMARY]
GO
SET ANSI_PADDING OFF
GO
Succes !