Parameters with same name in one query
From: Sascha Schroeder (sascha.schroeder_at_e-pro.de)
Date: 02/23/04
- Next message: Kevin Frevert: "Re: Parameters with same name in one query"
- Previous message: Richard Bibby: "Re: Importing the type library"
- Next in thread: Kevin Frevert: "Re: Parameters with same name in one query"
- Reply: Kevin Frevert: "Re: Parameters with same name in one query"
- Reply: Mike Walsh: "Re: Parameters with same name in one query"
- Reply: Sascha Schroeder: "Re: Parameters with same name in one query"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Mon, 23 Feb 2004 14:18:51 +0100
Hello,
i have a query string which contains a sub query, like:
SELECT *
FROM TABLE1
WHERE FIELD1 = :Param1 AND
FIELD2 IN
(SELECT FIELD2
FROM TABLE2
WHERE FIELD3 = :Param1)
I add the query to my query object and replace the parameters:
Query.ParamByName('Param1').AsInteger := 1;
My MSSQL-Server returns no rows but an error. I only get the
message in german, so i don't post it here. The message says, that
a parameter wasn't correct definied.
Is there a trick in ADO to do that? When i use the BDE there is no
problem to do that.
Thanks for your answers,
Sascha
- Next message: Kevin Frevert: "Re: Parameters with same name in one query"
- Previous message: Richard Bibby: "Re: Importing the type library"
- Next in thread: Kevin Frevert: "Re: Parameters with same name in one query"
- Reply: Kevin Frevert: "Re: Parameters with same name in one query"
- Reply: Mike Walsh: "Re: Parameters with same name in one query"
- Reply: Sascha Schroeder: "Re: Parameters with same name in one query"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|