Subject | Re: Upgrade problem |
---|---|
Author | Adam |
Post date | 2005-06-25T04:28:38Z |
Just a follow-up to Martijn's suggestion,
I recommend using parameters because then Delphi takes care of a lot
of the nasties for you.
Query.ParamByName('myvalue').AsString := tedit1.text;
But if you can't avoid dynamically building it, then there is a
function in Delphi StringReplace
MyValue := StringReplace(MyValue, CHR(39), CHR(39)+CHR(39),
[rfReplaceAll]);
Hope that helps
Adam
I recommend using parameters because then Delphi takes care of a lot
of the nasties for you.
Query.ParamByName('myvalue').AsString := tedit1.text;
But if you can't avoid dynamically building it, then there is a
function in Delphi StringReplace
MyValue := StringReplace(MyValue, CHR(39), CHR(39)+CHR(39),
[rfReplaceAll]);
Hope that helps
Adam