Skip to Main Content

SQLcl: MCP Server & SQL Prompt

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

25.1 project: export with emitSchema: false causes ORA-01471 on synonym creation

Moritz I.Jun 27 2025

Hi there!

I've exported (project export) my schema with project-config emitSchema: false, because the target-schema-name is different from the schema name where development is done. This is fine with all object types, no schema prefix, thus no problem deploying to the target schema.

BUT: with synonyms i ran into error ORA-01471: Ein Synonym kann nicht mit demselben Namen wie das Objekt erstellt werden.

Here the staged code:

create or replace editionable synonym odi_rt for odi_rt;

Background: the synonym has the same name as the referenced object in a foreign schema.

If i do the export with emitSchema: false i get a valid ddl:

create or replace editionable synonym moes_schema.odi_rt for control_schema.odi_rt;

But since i want to deploy into schema moes_prod_schema this statement won't work either.
Is there a way to configure the project to only omit the schema prefix for schema-local objects but not for referenced schemas?

I suppose the same applies to fk-constraints referencing parent tables in other schemas.

For now i'm only left with adding schema-prefixes in the synonym changesets manually. Quite a task with hundrets of synonyms.

This post has been answered by danmcghan-Oracle on Jul 8 2025
Jump to Answer
Comments
Post Details
Added on Jun 27 2025
4 comments
86 views