On 11/12/02 8:59 PM, "Phillip Rhodes" <rhodespc@stripped> wrote:
> I can not find anywhere that says that mysql supports table name synonyms.
> For example, I have two databases (test1 and test2) in the same mysql
> In test1 schema, there is a table called "table1"
> I would like to create a synonym whereby I could refer to test1.table1 as
> test2.table1 where test2.table1 does not exist.
This sounds like a CREATE VIEW statement ... And is not the same as a
synonym, If I am not wrong views will be introduced not before version 5 :-(
> I could do this in oracle as ..
> create public synonym table1 as test1.table1;
But you can have synonyms, they are just not persistent and exit only within
SELECT t1.fieldX, t2.fieldY
FROM table1 t1, table2 t2
WHERE t1.fieldY = t2.fieldX
t1, t2 are synonyms for table1 and table2 respectively.