Skip to content

Instantly share code, notes, and snippets.

@tsundara
Created October 19, 2018 14:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tsundara/82d8bb8a3f0f70d4e2285eaefc94255c to your computer and use it in GitHub Desktop.
Save tsundara/82d8bb8a3f0f70d4e2285eaefc94255c to your computer and use it in GitHub Desktop.
Oracle rename table : Quickest way to create or refresh an Oracle table from a view or select statement
DROP TABLE ZNEW;
create table znew as (select * from ANY_TABLE_OR_VIEW where col='value');
drop table ZMAIN;
alter table ZNEW rename to ZMAIN;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment