]of String;
i,l:integer;
function getsth(CurrEdit:TEdit):boolean;
begin
result:=false;
if CurrEdit.Text<>'' then
result:=true;
end;
begin
SQLAll:='';
SQLStr:='SELECT * FROM "仪器借出信息库.db" WHERE ';
if RadioGroup1.ItemIndex=1 then Log:='OR' else Log:='AND';
if Getsth(Edit_name) then
arrstr[1]:='(借用人='''+Edit_name.Text+''')';
if Getsth(Edit_No) then
arrstr[2]:='(仪器编号='''+Edit_No.Text+''')';
if Getsth(Edit_DateOut) then
arrstr[3]:='(借用日期='''+Edit_DateOut.Text+''')';
if Getsth(Edit_DateIn) then
arrstr[4]:='(归还日期='''+Edit_DateIn.Text+''')';
arrstr[5]:='';
for i:=1 to 4 do
begin
arrstr[5]:=arrstr[5]+arrstr[i];
if arrstr[i]<>'' then
SQLAll:=SQLAll+Log+arrstr[i];
end;
if arrstr[5]='' then
begin
showmessage('没有查询项目?');
exit;
end;