procedure TWL11_F.ComboBox1Change(Sender: TObject);
begin
with query1 do
begin
close;
sql.Clear;
sql.Add('select distinct ComboBox2列名 from 表名');
sql.Add('where ComboBox1的列名=:s0');
params[0].AsString:=ComboBox1.Text;
open;
first;
comboBox2.Items.Clear;
while not eof do
begin
ComboBox2.Items.Add(fieldbyname ('ComboBox2的列名').value);
next;
end;
end;
end;