Author Topic: How to Create Materialized view in Oracle  (Read 129 times)

0 Members and 1 Guest are viewing this topic.

Offline Corps

  • Sr. Member
  • *
  • Posts: 273
  • Karma: +0/-0
    • View Profile
How to Create Materialized view in Oracle
« on: November 01, 2008, 07:57:35 AM »
I am sharing this piece of code for our reference for those who want to know about Oracle.

How to create Materialized view in Oracle.

Code: [Select]

SET DEFINE OFF;
DROP SYNONYM DATAPPIS.MVW_DATA_ORG_UNITS_ALL;


DROP MATERIALIZED VIEW DATAMIS.MVW_DATA_ORG_UNITS_ALL;

CREATE MATERIALIZED VIEW DATAMIS.MVW_DATA_ORG_UNITS_ALL
TABLESPACE DATAD
NOCACHE
LOGGING
NOCOMPRESS
NOPARALLEL
BUILD IMMEDIATE
NEVER REFRESH
AS
SELECT DISTINCT
ORG_PARENT_ID, ORG_ID, ORG_NAME_PARENT, ORG_NAME, ORG_PARENT_MNEMONIC,
ORG_MNEMONIC, ORG_TYPE_PARENT, ORG_TYPE, DATE_FROM, DATE_TO
FROM VW_DATA_ORG_UNITS;

COMMENT ON MATERIALIZED VIEW DATAMIS.MVW_DATA_ORG_UNITS_ALL IS \'snapshot table for snapshot DATAMIS.MVW_DATA_ORG_UNITS_ALL\';

GRANT SELECT ON  DATAMIS.MVW_DATA_ORG_UNITS_ALL TO DATAPPIS;

CREATE SYNONYM DATAPPIS.MVW_DATA_ORG_UNITS_ALL FOR DATAMIS.MVW_DATA_ORG_UNITS_ALL;


Techronnati | where technology never sleeps

How to Create Materialized view in Oracle
« on: November 01, 2008, 07:57:35 AM »

Mountain View

 

Related Topics

  Subject / Started by Replies Last post
0 Replies
1088 Views
Last post November 27, 2008, 02:03:28 AM
by MrSpecialist
3 Replies
1651 Views
Last post February 17, 2015, 08:37:22 AM
by GBTalk
2 Replies
85 Views
Last post July 22, 2016, 05:25:34 AM
by nomadic
0 Replies
591 Views
Last post July 21, 2015, 01:55:14 AM
by JusticeLeague
2 Replies
90 Views
Last post July 21, 2016, 05:07:09 AM
by GBTalk

Posting Disclaimer: Any individual may post a message in this forum and may do so anonymously. Therefore, the sole author is exclusively and entirely responsible for all opinions in that message. They do not represent the official opinions of Techronnati, its administrators or moderators or the Techronnati Management. Techronnati is merely acting as an impartial conduit for constitutionally protected free speech and is not responsible and will not be held liable for the content of such messages. All images and service logos are trademarks of their respective owners.