Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 3 of 3 total
Thread Parameters not working
Thu, May 15 2008 8:50 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Tim

I've found another of those weirdo's where the query will not accept a parameter. I've had to replace

xrefFld.ParamByName('TableID').AsString := xTbl.Text;

with

xrefFld.SQL.Text :='SELECT Name, Type FROM Information.TableColumns WHERE TableName = '+QuotedStr(xTbl.Text)+' ORDER BY Name';

The original SQL was written as

SELECT Name, Type
FROM
Information.TableColumns
WHERE
TableName = :TableID
ORDER BY Name


This one isn't a problem since its only going to be called infrequently but the fact that it happens worries me.

Roy Lambert
Thu, May 15 2008 2:22 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

<< I've found another of those weirdo's where the query will not accept a
parameter. I've had to replace >>

Is this reproducible ?  If so, then please send me a sample project.

--
Tim Young
Elevate Software
www.elevatesoft.com

Fri, May 16 2008 3:44 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Tim

><< I've found another of those weirdo's where the query will not accept a
>parameter. I've had to replace >>
>
>Is this reproducible ? If so, then please send me a sample project.

I do like a good joke. Reproducible ha ha ha ha Smiley

I do encounter it every so often, most of the time I've been able to "cure" it by adding and deleting a blank line. In this case even retyping the entire statement had no effect. If I ever find it in something I can rip out you can be sure I'll send it.

I have an old version of the query generator component I've written which might exhibit the behaviour but as well as ElevateDB it uses TMS components so I guess you couldn't use it.

I think someone else said they'd had the same problem, if my memory is working correctly today and you read this can you post what you environment is and what components you have installed please.

Roy Lambert
Image