Re Steve
> Insert into Blah (Field1, :Param1) values (...
> would not work, but..
> Insert into Blah (Field1, Field2) values (:Param1, :Param2)
>
> ..WOULD work. You are attempting to parameterise the field names
themselves
> which is, as I understand it, a no-no.
If you consider it from the point of view of precomiling you could not
precompile a Query with parameterised
ColumnNames as the parameter subst could result in the query being invalid
However under ADO and MSSQL7 the following does work!
select
case :FieldNo
when 0 then Column1
when 1 then Column2
end
from Table
---------------------------------------------------------------------------
New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED]
with body of "unsubscribe delphi"