Search
 
SCRIPT & CODE EXAMPLE
 

SQL

how to get ddl for materialized view

-- Views (use USER_VIEWS or DBA_VIEWS if needed):
SELECT TEXT FROM ALL_VIEWS WHERE upper(VIEW_NAME) LIKE upper('%VIEW_NAME%');
-- Or:
SELECT dbms_metadata.get_ddl('VIEW', 'VIEW_NAME', 'OWNER_NAME') FROM DUAL;

-- Materialized views (use USER_VIEWS or DBA_VIEWS if needed):
SELECT QUERY FROM ALL_MVIEWS WHERE upper(MVIEW_NAME) LIKE upper('%VIEW_NAME%');
-- Or:
SELECT dbms_metadata.get_ddl('MATERIALIZED_VIEW', 'VIEW_NAME', 'OWNER_NAME') 
FROM DUAL;
Comment

PREVIOUS NEXT
Code Example
Sql :: oracle split string 
Sql :: tsql rename table 
Sql :: postgres get database encoding 
Sql :: set all the vluses in calumn in sql to false 
Sql :: date_format for time sql 
Sql :: mssql cursor 
Sql :: search query in mysql 
Sql :: convert series number to date in sql 
Sql :: last 6 months postgresql 
Sql :: oracle alter table add not null constraint 
Sql :: creating a view sql 
Sql :: mysql default port 
Sql :: sql drop table statement 
Sql :: if then else sqlite 
Sql :: Oracle Column Names of a table 
Sql :: ksql terminate all queries 
Sql :: what is initial catalog in sql connection string 
Sql :: oracle alter table add column not null 
Sql :: sql create table with datetime automatically 
Sql :: how to define a composite primary key in sql 
Sql :: mysql persistence.xml 
Sql :: sql server cannot create database diagram 
Sql :: possgress drop if exists view 
Sql :: create table with select 
Sql :: join to find results not in another table 
Sql :: psql datetime grather than 
Sql :: sql remove not null constraint 
Sql :: select latest entry in sql table 
Sql :: sql count having 
Sql :: null column to 0 in mysql 
ADD CONTENT
Topic
Content
Source link
Name
5+5 =