?? bugnet_bugnotification_createnewbugnotification.sql
字號:
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[BugNet_BugNotification_CreateNewBugNotification]') AND type in (N'P', N'PC'))
DROP PROCEDURE [dbo].[BugNet_BugNotification_CreateNewBugNotification]
GO
CREATE PROCEDURE [dbo].[BugNet_BugNotification_CreateNewBugNotification]
@BugId Int,
@NotificationUsername NVarChar(255)
AS
DECLARE @UserId UniqueIdentifier
SELECT @UserId = UserId FROM aspnet_Users WHERE Username = @NotificationUsername
IF NOT EXISTS( SELECT BugNotificationId FROM BugNotification WHERE CreatedUserId = @UserId AND BugId = @BugId)
BEGIN
INSERT BugNotification
(
BugId,
CreatedUserId
)
VALUES
(
@BugId,
@UserId
)
RETURN scope_identity()
END
GO
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -