对于存储过程的执行来说不能使用以下方法:
declare @n int
declare @a int
declare @b int
set @n=1
while @n<=100000
begin
--set @a=ceiling(rand()*4)
--set @b=ceiling(rand()*6)
exec [dbo].[BL_Lead]ceiling(rand()*4),ceiling(rand()*6),'测试角色'+ltrim(@n),'测试角色'+ltrim(@n)+'的logo','测试角色'+ltrim(@n)+'的店铺','测试角色'+ltrim(@n)+'的店铺的logo',@n
set @n=@n+1
end
其中有2个错误:
第一 在存储过程执行的时候不容许使用rand()函数
第二 在存储过程执行的时候不容许使用+号
declare @n int
declare @a int
declare @b int
set @n=1
while @n<=100000
begin
--set @a=ceiling(rand()*4)
--set @b=ceiling(rand()*6)
exec [dbo].[BL_Lead]ceiling(rand()*4),ceiling(rand()*6),'测试角色'+ltrim(@n),'测试角色'+ltrim(@n)+'的logo','测试角色'+ltrim(@n)+'的店铺','测试角色'+ltrim(@n)+'的店铺的logo',@n
set @n=@n+1
end
其中有2个错误:
第一 在存储过程执行的时候不容许使用rand()函数
第二 在存储过程执行的时候不容许使用+号