Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat. The purpose of this eBook is to educate the reader about ransomware attacks.
Thanks a lot in advance
USE [STRAINING] GO /****** Object: StoredProcedure [dbo].[sp_SignUp] ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO ALTER PROCEDURE [dbo].[sp_SignUp] @cosID int, @locid int, @dat int, @UserName varchar(50) AS BEGIN -- SET NOCOUNT ON added to prevent extra result sets from -- interfering with SELECT statements. declare @error varchar(max) SET NOCOUNT ON; if exists(SELECT * FROM tblTrainings WHERE Username = @UserName AND CourseID = @cosID AND LocationID = @locid AND dateId = @dat) begin set @error = 'You have already signed up for this training' raiserror(@ERROR, 12, 1) end else DECLARE @seatsAvailable int SET @seatsAvailable = 0; SELECT @seatsAvailable = (select Seating_Capacity - (select count(*) from tblTrainings WHERE CourseId=@cosID ) FROM tblLocations WHERE LocationId = @locID ) if @seatsAvailable > 0 begin INSERT INTO tblTrainings (CourseId, LocationId, dateId, username) VALUES (@CosID, @LocID, @dat, @Username) set @error = Registration is successful' raiserror(@ERROR, 13, 1) end else begin INSERT INTO tblWaitingList (CourseId, LocationId, dateId, username) VALUES (@CosID, @LocID, @dat, @Username) set @error = 'You have been placed on the waiting list. You will be immediately notified if a seat is available' raiserror(@ERROR, 14, 1) end END
|Error executing dynamic sql using SQL Server 2008, I get the following error: Procedure or function proc_CSL_ChkTableForNull has too many arguments specified||1||29|
|Rename SQL Instance/SQL Developer Edition 2012||2||11|
|Help Parsing a String with SQL Syntax||23||28|
|When I execute a stored proc with input parms using SQL Server 2008, I get the following error msg: Msg 8152 String or binary data would be truncated. Do you know how I can resolve this?||1||12|
Join the community of 500,000 technology professionals and ask your questions.
Connect with top rated Experts
11 Experts available now in Live!