DECLARE @nMinimumCount INT= 1DECLARE @nMaximumCount INT= 100SELECT abs(CHECKSUM(NEWID()))%(@nMaximumCount+ 1-@nMinimumCount)+@nMinimumCount@nMinimumCount ,@nMaximumCount为指定获取随机数的最小和最大范围