Skip to Main Content

Java Development Tools

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!

generate SQL scripts : schema name prefix issue

Jan VerveckenFeb 24 2009 — edited Mar 4 2009
hi

Using JDeveloper 10g (10.1.3.4.0) I created a Database Diagram and dropped both SCOTT.EMP and SCOTT.DEPT tables on it, creating Offline Database Objects.
After that I used the "Generate or Reconcile Objects..." option from the right-click menu on the SCOTT Offline Database Source in JDeveloper, to generate a SQL script.

The result can be found in this example application:
http://verveja.footsteps.be/~verveja/files/oracle/GenerateSQLScriptsIssueApp-v0.01.zip

Although the option "Prefix object name with schema name" was not selected, the resulting script contained this code, referring to SCOTT.DEPT instead of DEPT
PROMPT create foreign key constraint on 'EMP'
ALTER TABLE EMP
ADD CONSTRAINT WORKS_IN_DEPT FOREIGN KEY
(
DEPTNO
)
REFERENCES SCOTT.DEPT
(
DEPTNO
)
ON DELETE SET NULL ENABLE
;
How can I avoid the use of the schema name prefix in such a generated SQL script?
This schema name prefix prevents that the generated script can be run in a different database schema.

many thanks
Jan Vervecken
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 1 2009
Added on Feb 24 2009
6 comments
780 views