I want to use OraQuery to select something use param, but I found that it's no use. Please look at this cood:
Code: Select all
//1. using param
OraQuery1.SQL.Text:='select * from ttttxt002105 where t$kwd2=:KWD2';
OraQuery1.Params.ParamByName('KWD2').AsString:='SFC000523';
OraQuery1.Active:=True;
ShowMessage(IntToStr(OraQuery1.RecordCount)); //RecordCount = 0
//2. not use param
OraQuery1.SQL.Text:='select * from ttttxt002105 where t$kwd2=''SFC000523''';
OraQuery1.Active:=True;
ShowMessage(IntToStr(OraQuery1.RecordCount)); //RecordCount = 1
It's that OraQuery's Bug?
Environment:
Delphi 7, XP SP3, Oracle 10g