Hi Rob
Not Access, but I use ADOQuery.Parameters.ParamByName('pName').Value := xx;Value is a variant property, so there is no typecasting till runtime :-(, but it works in all the ADO environments that I have used. There is no .AsString, AsInteger, ... with a TParameter.
HTH
Stephen
----- Original Message ----- From: "Robert martin" <[EMAIL PROTECTED]>
To: "NZ Borland Developers Group - Delphi List" <[email protected]>
Sent: Wednesday, April 20, 2005 3:11 PM
Subject: [DUG] One for the ADO guys
Hi
I am trying to use ADO to access an ACCESS database. This is all working fine. However all my SQLs up until now have been unparameterized. I want to use the following query because ClientAddress can contain 's. However I am struggling to fill in the parameteres.
UpdateADOQuery.SQL.Text := 'UPDATE ClientInfo ' +
'SET ClientName =
:ClientName, ' +
'ClientAddress =
:ClientAddress, ' +
'WHERE EntityRef = :EntityRef;';
In my IBObjects / Firebird stuff I would go Query.ParamByName('ClientAddress').AsString := 'asdfsdfdsf'; How do I do this in ADO?
Feeling really stupid today (not aided by the fact I cant test it on my dev machine and have to run it each time to find I have used the wrong property !!)
Help please :)
-- Rob Martin Software Engineer
phone +64 03 377 0495 fax +64 03 377 0496 web www.chreos.com
Wild Software Ltd
_______________________________________________
Delphi mailing list
[email protected]
http://ns3.123.co.nz/mailman/listinfo/delphi
_______________________________________________ Delphi mailing list [email protected] http://ns3.123.co.nz/mailman/listinfo/delphi
