------------------------------------------------------------------
--                                                              --
--  File:   Checkpoint_TPCE_Database.SQL                        --
--          Microsoft TPC-E Benchmark Kit Ver. 1.12.0-1025      --
--          Copyright Microsoft  2010, 2011, 2012               --
--                                                              --
------------------------------------------------------------------
USE	tpce
GO

DECLARE	@i			int,
		@loops		int,
		@date       datetime,
		@time		datetime,
		@timestr	varchar(10)

SET     @time	= getdate()

WHILE (2 > 1)
BEGIN

    SET @date   = CONVERT(DATETIME, CAST(getdate() AS BIGINT))
    
    SET @time   = DATEADD(second, 448, GETDATE() - @date)
    
    CHECKPOINT  420
    
    IF (GETDATE() - @date) < @time
        WAITFOR TIME @time
    
END
