This site is currently read-only as we are migrating to Oracle Forums for an improved community experience. You will not be able to initiate activity until January 31st, when you will be able to use this site as normal.

    Forum Stats

  • 3,890,747 Users
  • 2,269,776 Discussions
  • 7,916,827 Comments

Discussions

sqlcl COPY/REPLACE implementation does not drop existing table

B.Delmée
B.Delmée Member Posts: 609 Silver Badge
edited Oct 12, 2020 7:15AM in SQLcl

I am using sqlcl 19.1 on RHEL 7.7. I think the implementation of the sql*plus COPY command (in its REPLACE variant) might be faulty.

The documentation says:

Replaces destination_table and its contents with the rows from query. If destination_table does not exist, COPY creates it. Otherwise, COPY drops the existing table and replaces it with a table containing the copied data.

But here's what i am getting when the destination table already exists:

Statement create table "SOME_TABLE" (...) failed, error message: ORA-00955: name is already used by an existing object

COPY_DESTINATION_WAS_NOT_CREATED.