A
alan5421
Unregistered / Unconfirmed
GUEST, unregistred user!
adoQuery2.Close;
adoQuery2.SQL.Clear;
adoQuery2.SQL.Add('select * from lb where 人员编号=:bh order by 日期 asc');
adoQuery2.Parameters.ParamByName('bh').Value:=adoQuery1.FieldValues['编号'];
adoQuery2.Open;
老提示:parameter 'bh' not found
注:adoQuery1是打开的,而且也找到记录了,‘人员编号’是lb表中的字段,自己建的,是整形,‘编号’是另一个表中的字段,是数据表的自动编号,我需要用第一个DBGird中当前记录的‘自动编号’在第二个表中查找与之相关的记录。
adoQuery2.SQL.Clear;
adoQuery2.SQL.Add('select * from lb where 人员编号=:bh order by 日期 asc');
adoQuery2.Parameters.ParamByName('bh').Value:=adoQuery1.FieldValues['编号'];
adoQuery2.Open;
老提示:parameter 'bh' not found
注:adoQuery1是打开的,而且也找到记录了,‘人员编号’是lb表中的字段,自己建的,是整形,‘编号’是另一个表中的字段,是数据表的自动编号,我需要用第一个DBGird中当前记录的‘自动编号’在第二个表中查找与之相关的记录。