Board index » delphi » Join Multiple Databases' table using TQuery

Join Multiple Databases' table using TQuery

I am facing problem when i try to join two tables in two different
database using TQuery. I use two alias name for the databases, but i
get the error "operation not applicable".
SQL statement that i used is :-
Select * from ":Alias1:Table1", ":Alias2:Table2"

 

Re:Join Multiple Databases' table using TQuery


Did you use two single quotes or a double quote? The example in the
book (database application developer's guide) page 119 uses two single
quotes. Also, do you have a local alias for the result table? That
goes in the database name property of the tquery.

On Thu, 08 Jan 1998 17:19:20 GMT, simf...@pl.jaring.my (Sam Chong)
wrote:

Quote
>I am facing problem when i try to join two tables in two different
>database using TQuery. I use two alias name for the databases, but i
>get the error "operation not applicable".
>SQL statement that i used is :-
>Select * from ":Alias1:Table1", ":Alias2:Table2"

hth,

--
Dan Brennand
CMDC systems, inc.
Configuration Management and Document Control: Consulting, Software,
and the only comprehesive textbook on this subject.
visit us at www.cmdcsystems.com
[Remove the SPAM from my e-mail address]

Re:Join Multiple Databases' table using TQuery


Where instruction ??
...
select *
from ':alias1:table1' A
       ':alias2:table2' B
where A.field1 = B.Field2

Sam Chong a crit dans le message <34b60a8d.3118...@news2.jaring.my>...

Quote
>I am facing problem when i try to join two tables in two different
>database using TQuery. I use two alias name for the databases, but i
>get the error "operation not applicable".
>SQL statement that i used is :-
>Select * from ":Alias1:Table1", ":Alias2:Table2"

Other Threads