Hi tell me why the application not call this procedure?
ALTER PROCEDURE [dbo].[proc_GenerateRandomTicket_ImportOsoba] AS BEGIN DECLARE @Random numeric(10,0); DECLARE @Upper numeric(10,0); DECLARE @Lower numeric(10,0); DECLARE @TicketCode VARCHAR(10); DECLARE @i smallint=0; SET @Lower =268435456; -- The lowest random 32 bits number SET @Upper = 4294967295; -- The highest random 32 bits number
WHILE @i < 200
Begin SELECT @Random = ROUND(((@Upper-@Lower-1) * RAND() + @Lower), 0); SELECT @TicketCode = CONVERT(VARCHAR(10), @Random);
EXEC [dbo].[proc_ImportOsoba_Bilety] @TicketCode;
SET @i = @i + 1 END