SQL & PL/SQL :: PCT Is Not Enabled While Creating Mview / Though Base Tables Are Partitioned
Apr 4, 2011
I created a mv for one of the partitioned tables but on viewing the mv capabilities it still shows PCT is set to 'N'.
create materialized view MV_summary_SEC
refresh fast
start with sysdate
nEXT SYSDATE + 1/24
enable query rewrite as
[code]....
If i remove the sub query and create the mview like this,then PCT is enabled.
create materialized view MV_summary_SEC
refresh fast
start with sysdate
nEXT SYSDATE + 1/24
enable query rewrite as
select PERIOD , SUM(SUM_WEB_HITS)
from summary ,date_table
where PERIOD >= DATE_TABLE.CUR_DATE
group by PERIOD
Is it simply because oracle doesn't support PCT if the definition contains subqueries ?
View 4 Replies
ADVERTISEMENT
Dec 9, 2010
I have a view on base tables holding historical data for previous 60 months(one table per month) with union all operators.create index on those base tables will improve performance or creating a primary key with disabled novalidate will improve for retrieving data?
The view has around 8 million data and used as a fact table with 4 dimension tables.A DTS package from MSSql side refreshes OLAP cube by retrieving data from these tables in oracle.
View 1 Replies
View Related
Apr 19, 2013
Is it possible to get a list of tables in a schema on which Audits are enabled.
View 2 Replies
View Related
Jan 30, 2013
I'm currently having a problem with regards to Exporting data to another server. This is the Scenario:Source Server is Production Server with all of its Tables in the Schema are Version-Enabled.
Destination Server is a Test Server.I exported data from Production Server using EXP command. Then in my Test Server I imported my data using IMP command (I already created tablespace and user for the Schema).Import is successful in my Test server but when I execute my queries, There are no rows returned.
I checked my _LT tables and it contains my data. but when I query from the View created when version was enabled, no result is returned.Am I missing something when I exported and imported my Schema? Should I have included the WMSYS schema when I created the .dump file?
View 10 Replies
View Related
Jan 2, 2013
I would like to ask about indexes in partitioned tables.I have indexes on a partitioned table, it is partitioned by range method i.e based on Creation date time.All select queries sent to the table use the Creation date time. I have an index on Creation date time.Here is an example:
SELECT col1, col2, col3
FROM table1 where
date_time BETWEEN TO_DATE ('20120117 10:00:00','YYYYMMDD HH24:MI:SS')
AND TO_DATE ('20120117 13:00:00','YYYYMMDD HH24:MI:SS')
AND frmt_name = 'XXXX'
AND sender = 'YYYYY'
AND nature = 'ZZZZ'
AND type LIKE '548'
ORDER BY date_time
WHERE ROWNUM <= 5000
[code]....
do I have to add DATE_TIME to all indexes (IX_NAME_FORMAT_TYPE,IX_CCY) or not?
View 6 Replies
View Related
Jul 22, 2012
how DBMS_REDEFINITION online reorg works with partitioned tables. I have a table with 6 partitions and I want to reorrg whole table...
View 43 Replies
View Related
Aug 23, 2010
understand on the below regarding partitioning table and indices.
1. How to know if each partition have LOCAL index or Global index?
I had the above question duw to the beloe reason :
I have a table with 130 partitions and 7 indices. When checked the DBA_IND_PARTITIONS it lists down only 1 index name (which distinct) for all the 130 partitions.
Does it mean it is a Global index? If Global index, is it partitioned? How to get those information?
2. Assuming, if i have LOCAL indices for every partitions, from where i shall nail down the name of each local index and how would i get the detail of referencing Global index?
3. By which type a table was partitioned? LIST,HASH,RANGE ?
View 2 Replies
View Related
Sep 25, 2012
we are looking to use oracle 11g as a log database using partitioned tables.
- The tables will have only a 3-5 columns of ~varchar(50) size
- We are looking at a volumn of ~33million rows (inserts) per day.
1) Will partitioned tables be able to handle this type of volume?
2) if yes, will a Composite Partitioning (using last modified datetime as range) then subparition with range be the best choice?
if this type of volume is too high for 11g, what are some of the alternative products we can use.
View 5 Replies
View Related
Feb 4, 2005
16:28:32 SQL> create bitmap index bp_idx_ag_id on transactions(type);
create bitmap index bp_idx_ag_id on transactions(type)
*
ERROR at line 1:ORA-25122: Only LOCAL bitmap indexes are permitted on partitioned tables
how to create bitmap index on partitiioned tables
View 3 Replies
View Related
May 13, 2013
that are my biggest tables
Users use front end (called ESS Console) and when they try to open one of those tables they wait very long (really bad performance). Sometimes the GUI even hanging without displaying results.
Does Partitioned Tables feature works for better performance?
View 3 Replies
View Related
Dec 3, 2011
So I'm here creating some tables and if theres a guide where I can take a look at some Constraints Declarations , Mostly cause i have some values on the table that cannot be negative so i need to set constraints to be positive
View 4 Replies
View Related
Aug 19, 2013
Explain in detail about using constraints in creating tables.
View 3 Replies
View Related
Jan 26, 2011
I have created a softlink to a data file orig_file.dat using the command ln -s orig_file.dat orig_file_link.dat
Now is it possible to create an external table using this linked file orig_file_link.dat
I am using this linked file to minimise the space usage because every month we get different data files and external table creation is done as a batch job copying the data file to another file whenever a new data file arrives. External table is created with the new file. so i need to check whether it is possible with the linked file instead of copying the file.
View 6 Replies
View Related
Oct 30, 2011
I am trying to create a new user who will be able to do a delete from all of the tables that only I MYSELF created. I created my user and granted access but realized I may not have done it right..
is it simply SQL>grant delete on <TABLESPACE> to <new user>; ? or do i need to specify the grant the delete on my tablespace to new user?
View 4 Replies
View Related
Jul 19, 2010
I am facing a problem while creating a program using oracle forms.These two table i am using in creating following program .
SQL> desc electricity ;
Name Null? Type
----------------------------------------- -------- ----------------------------
ID NOT NULL NUMBER
NAME VARCHAR2(40)
PREV_READING NUMBER(20)
PRESENT_REDAING NUMBER(20)
TOTAL_UNITS NUMBER(30)
AMOUNT NUMBER(30)
[code]....
What i want that whenever user writes a value in "PRESENT_Reading" Column then it stores value in "ID table" .For example if current month is July ,Then when user write a value in present Reading column ,it stores it in JULY Column of Id table ..i Write following trigger (Key_commit) On present_reading Column .
if sysdate=to_char(sysdate,'MON','Jan') Then
:electricity.PRESENT_REDAING := :ID.Jan ;
elsif
sysdate=to_char(sysdate,'MON','FEB') Then
:electricity.PRESENT_REDAING := :ID.Feb ;
elsif
sysdate=to_char(sysdate,'MON','MAR') Then
:electricity.PRESENT_REDAING:= :ID.MAR ;
But when i run my form it does not work ,and raised unhandled Exception .I think i need to change some properties of PRESENT_READING column of electricity table.
View 7 Replies
View Related
Oct 10, 2013
I'm having trouble with a little assignment.
"Create a view named vuPassFailRate that will show the pass rate and fail rates of each test."
I have a table named Test_ID containing the following columns:
TEST_ID
TEST_NAME
PASSING_GRADE
And another table named Test_History containing the following columns:
TEST_ID
STUDENT_ID
SCORE
I'm assuming i have to create an inline view, and to work out the pass/fail rates i need to do something along the lines of (For pass rate) Where SCORE is greater than or equal to PASSING_GRADE, and TEST_ID equals TEST_ID, divide by a count of SCORE and multiply by 100. I just cant work out the nested select statements, and work out the formula using two columns in two tables.
I have been staring at this problem for so long now i cant see the wood for the trees.
View 3 Replies
View Related
Apr 30, 2010
SQL> connect sys as sysdba
Enter password:
Connected.
SQL> grant dba to temp;
Grant succeeded.
SQL> connect temp
Enter password:
Connected.
SQL>
SQL> create or replace procedure tempproc
2 is
3 begin
4 execute immediate 'create table temp_table(a varchar2(10))';
5 end;
6 /
Procedure created.
SQL> exec tempproc;
BEGIN tempproc; END;
*
ERROR at line 1:
ORA-01031: insufficient privileges
ORA-06512: at "TEMP.TEMPPROC", line 4
ORA-06512: at line 1
SQL>
SQL> declare
2 begin
3 execute immediate 'create table temp_table(a varchar2(10))';
4 end;
5 /
PL/SQL procedure successfully completed.
SQL> desc temp_table;
Name Null? Type
----------------------------------------- -------- ----------------------------
A VARCHAR2(10)
Why am I not able to create a table from procedure using execute immediate?
View 3 Replies
View Related
Dec 5, 2012
This is just for learning purposes. What if I would like to create my own materialized view utilizing only tables and a job.
View 28 Replies
View Related
Oct 10, 2013
I'm having trouble with a little assignment. "Create a view named vuPassFailRate that will show the pass rate and fail rates of each test." I have a table named Test_ID containing the following columns:
TEST_IDTEST_NAMEPASSING_GRADE
And another table named Test_History containing the following columns:
TEST_IDSTUDENT_IDSCORE
I'm assuming i have to create an inline view, and to work out the pass/fail rates i need to do something along the lines of (For pass rate) Where SCORE is greater than or equal to PASSING_GRADE, and TEST_ID equals TEST_ID, divide by a count of SCORE and multiply by 100. I just cant work out the nested select statements, and work out the formula using two columns in two tables. I have been staring at this problem for so long now i cant see the wood for the trees.
View 2 Replies
View Related
Jun 10, 2013
I have a database in my Windows 2003 server and oracle 9i installed on it working find. we are using our client pc on the network to access the database on the server through our application program which is build under java swing.I want to create a client application which will use the browser to access the database only for generating reports.
View 1 Replies
View Related
Jun 20, 2012
I want to do a tree view based on the following tables in APEX:
create table plattform (
id number,
name varchar2(200))
create table environment (
id number,
plattform_id number,
name varchar2(200))
[code].....
View 4 Replies
View Related
Dec 30, 2010
I am trying to restore to a backup instance on a backup server. When I try to recreate the tables I keep getting ORA-01659: unable to allocate MINEXTENTS. The tablespaces and datafiles on both servers show as the same size in OEM.
I have dropped all tables and OEM shows tablespaces are empty. Then I run a script to recreate all tables. Most of the tables don't get created because their TS is full. After the script to recreate all tables runs, the main tablespaces are full, more full than on the production machine. I have also tried ALTER TABLESPACE xxx COALESCE; on each tablespace right after dropping all tables and before recreating them to reclaim free space. Why is it full? I've only dropped and created the tables, there shouldn't be any data in them yet.
ORA-01659: unable to allocate MINEXTENTS beyond 2 in tablespace PLUS_T...The backup instance was already there, all I did was drop the tables. Here's what I ran on prod to build a script to recreate the tables on backup server. Got it off Burleson somewhere.
SELECT DBMS_METADATA.GET_DDL('TABLE',u.table_name) ||'; '
FROM USER_TABLES u;
View 4 Replies
View Related
Aug 20, 2010
I am writing a procedure that will be called from a java wrapper.
The procedure do a lot of data manipulations and in between i am creating global temp table and saving the data into it for each request thats given as a parameter to the procedure. After all the processing i have to write the data from this global temp table into a physical table and atlast drop the temp table.
Create or replace proc_name ()
update table........
delete from ..........
CREATE GLOBAL TEMPORARY TABLE TSAAG
( supplier_id numeric(10) not null,
supplier_name varchar2(50) not null,
contact_name varchar2(50)
)
insert into............
drop table TSAAG;
End;
creating a global temp table inside a procedure is expensive...
Do we have anything like creating table before and calling the instanse of it in procedure.
Do we have any alternatives to this..
View 3 Replies
View Related
Sep 10, 2012
RDBMS - 11.1.0.7, I it possible to convert indexes of a non-partitioned table to hash partitioned indexes by retaining table as non-partitioned?
If yes, is this what it is Creating a Hash-Partitioned Global Index - can be created for partitioned and non-partitioned tables?
View 7 Replies
View Related
Nov 1, 2012
what is the best way to partitioned a non-partitioned table to partitioned table date wise? I have data from last four year?
View 4 Replies
View Related
Jun 4, 2012
I have a mview based on the database link. Mview created without the error and first time refrehment has been done properly in time, but after the first time it is not refreshing.
CREATE MATERIALIZED VIEW "SMSCHAT"."TBL_VOICECHAT_NEW1"
ORGANIZATION HEAP PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS NOLOGGING
STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
TABLESPACE "SMSCHAT"
BUILD IMMEDIATE
USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255
STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
[code].....
I have set the refreshment time for mview for 15 min with the following command
alter MATERIALIZED VIEW SMSCHAT.TBL_VOICECHAT_NEW1 REFRESH FAST START WITH sysdate+0 NEXT sysdate+(15/86400*60);
But now this mview is not refreshing and no jobs is showing in dba_jobs_running.
18:10:32 SQL> select LAST_DATE,LAST_SEC,THIS_DATE,THIS_SEC,NEXT_DATE,NEXT_SEC,TOTAL_TIME,BROKEN from dba_jobs where job=234;
LAST_DATE LAST_SEC THIS_DATE THIS_SEC NEXT_DATE NEXT_SEC TOTAL_TIME B
-------------------- -------- -------------------- -------- -------------------- -------- ---------- -
04-jun-2012 17:47:13 17:47:13 04-jun-2012 18:02:13 18:02:13 34 N
View 11 Replies
View Related
Sep 11, 2013
I have 5 MViews that I want to refresh in two occassions, every sundays and at the 1st of the month. I created a Refresh Group for the weekly and that work fine. But when I tried to created the second Refresh Group for the monthly I get a "materialized view is already in a refresh group".
You can only have a materialized view in one refresh group? What options to I have to refresh it in different intervals?
View 1 Replies
View Related
Feb 17, 2011
My MVIEW has a refresh rate (sysdate + 1 ) + 24/24 So how often it gets refreshed .
View 3 Replies
View Related
Jan 11, 2011
I have created the snapshot as
CREATE SNAPSHOT EMPLOYEE_CRIS_MVIEW
PCTFREE 10
PCTUSED 40
MAXTRANS 255
TABLESPACE users
[code].........
The date format for the column join_dt is dd-mon-yyyy. But I want to modify the date format for this column as 'MM/DD/YYYY'.
For that I tried
ALTER snapshot EMPLOYEE_CRIS_MVIEW modify(TO_CHAR(join_dt,'MM/DD/YYYY'));
But I got the error
ERROR at line 1:
ORA-00902: invalid datatype
change the date format of the column of the snapshot with out dropping the snapshot.
View 2 Replies
View Related
Dec 14, 2010
We have created this Mview in two schemas i.e.MRD and MRDSEIn MRD schema we are getting the date format is MM/DD/YYYY where as in MRDSE we are getting the format DD-MON-YYYY. why we are getting the difference in date format in two schemas.We are not modifying any thing.
Here is DATAENCRYPTION Package.
ENCRYPTDATA Function.
We are getting this date format issue only for the ENCRYPETED date columns in MRDSE.
MM/DD/YYYY
We are not getting this date format issue for the ENCRYPETED date columns in MRD.
DD-MON-YYYY
CODECREATE OR REPLACE VIEW emp_join_vw (
encr_emp_nr,
[code]...
View 2 Replies
View Related