Result set (i think) This is the other SPALTER PROCEDURE [dbo].[sp_GeneratePassword]( @Length int)ASDECLARE @RandomID varchar(32)DECLARE @counter smallintDECLARE @RandomNumber floatDECLARE @RandomNumberInt tinyintDECLARE @CurrentCharacter varchar(1)DECLARE @ValidCharacters varchar(255)SET @ValidCharacters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'DECLARE @ValidCharactersLength intSET @ValidCharactersLength = len(@ValidCharacters)SET @CurrentCharacter = ''SET @RandomNumber = 0SET @RandomNumberInt = 0SET @RandomID = ''SET NOCOUNT ONSET @counter = 1WHILE @counter < (@Length + 1)BEGIN SET @RandomNumber = Rand() SET @RandomNumberInt = Convert(tinyint, ((@ValidCharactersLength - 1) * @RandomNumber + 1)) SELECT @CurrentCharacter = SUBSTRING(@ValidCharacters, @RandomNumberInt, 1) SET @counter = @counter + 1 SET @RandomID = @RandomID + @CurrentCharacterENDSELECT @RandomID AS 'Password'