Hi,
I have 2 tables and would like to return the name of an agent from table 2 by its ID in table 1. In php/MySql I would do something like this:
However in Delphi using a TQuery I have problems with the syntax as the table names are identified by their filename.
I tried:
But no results.
Is this possible anyway or should I use an alias (which I am trying to avoid)?
Thanks!
Raoul
I have 2 tables and would like to return the name of an agent from table 2 by its ID in table 1. In php/MySql I would do something like this:
SELECT table2.MyAgent FROM table1,table2 where table1.MyAgent = table2.ID
However in Delphi using a TQuery I have problems with the syntax as the table names are identified by their filename.
I tried:
SELECT table2.db.MyAgent FROM table1.db,table2.db where table1.db.MyAgent = table2.db.ID
But no results.
Is this possible anyway or should I use an alias (which I am trying to avoid)?
Thanks!
Raoul