T_SQL用循环语句向表中插入测试数据
declare @i int
set @i=10
while @i<20
begin
insert into ceshitwo(Title,Author,Source)
values('Title'+cast( @i as varchar),'Author'+cast( @i as varchar),'Source'+cast( @i as varchar))
set @i=@i+1
end
set @i=10
while @i<20
begin
insert into ceshitwo(Title,Author,Source)
values('Title'+cast( @i as varchar),'Author'+cast( @i as varchar),'Source'+cast( @i as varchar))
set @i=@i+1
end