var stutid:integer; i: integer;begin for i:=0 to 19 do begin Randomize; stuid:=random(最大的学生id); query1.sql.clear; query1.sql.add('select * from student where studentid=:stuid') // 将取出来的记录做处理; // end; end;
Randomize() can't ensure distinct.if you execute 'select 'again and again every method can't ensure distinct too, beacause the recordcount of the table is limited.
Randomize() can't ensures distinct.if you execute SQL statement 'select... 'again and again any method can't ensures distinct result too, beacause the recordcount of the table is limited.
stutid:integer;
i: integer;begin
for i:=0 to 19 do
begin
Randomize;
stuid:=random(最大的学生id);
query1.sql.clear;
query1.sql.add('select * from student where studentid=:stuid')
//
将取出来的记录做处理;
//
end;
end;
every method can't ensure distinct too,
beacause the recordcount of the table is limited.
any method can't ensures distinct result too,
beacause the recordcount of the table is limited.