Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: From Oracle to Mysql
"JPM" <jperezme_at_jazzfree.com> wrote:
>Hello.
>I'm trying to build a sql sentence from oracle to mysql but it doesn't
>works.
>Anyone knows how to do this works on mysql ?
>
>CREATE PUBLIC SYNONYM AULA FOR AULAS;
>
>Thanks.
I quick search at www.mysql.com found:( so you could have tried harder, I think)
The CREATE SYNONYM statement defines a synonym (alternative name) of a table name.
Syntax
<create_synonym_statement> ::= CREATE [PUBLIC] SYNONYM [<owner>.]<synonym_name> FOR <table_name>
owner, synonym_name, table_name
Explanation
The table name must not denote a temporary base table (see Table). The user must have a privilege for the specified table. The current user must be the owner.
The synonym name can be specified anywhere instead of the table name. This has the same effect as specifying the table name for which the synonym was defined.
PUBLIC If PUBLIC is specified, the synonym name must not be identical to the name of a synonym defined with PUBLIC. A synonym is generated that can be accessed by all users.
If PUBLIC is not specified, a private synonym is generated that is only known by the current user. In this case, the synonym name must not be identical to the name of an existing base table, view table, or a private synonym of the current user. If a synonym with the same name and the PUBLIC attribute exists, it cannot be accessed by the current user until the private synonym has been dropped.
![]() |
![]() |