Kod: Tümünü seç
begin
if Edit3.Text='' then
begin
Application.MessageBox('ARANACAK CD YAZINIZ.','UYARI',MB_OK+MB_ICONERROR);
end else begin
Query1.Close;
Query1.SQL.Clear;
Query1.SQL.Add('select * from cdkayit');
if RadioGroup1.ItemIndex=0 then
begin
Query1.SQL.Add('where CDKOD=:cdkod');
Query1.ParamByName('cdkod').AsInteger:=StrToInt(Edit3.Text);
end;
if RadioGroup1.ItemIndex=1 then
begin
Query1.SQL.Add('where CDTUR like:cdtur');
Query1.ParamByName('cdtur').AsString:=Edit3.Text+'%';
end;