Partition view on 10g and 11g
Hi All,
I am on 10.2 Standard edition and 11.1 Standard edition (2 databases in the application, one on 10g, another on 11g).
Being on standard edition, cannot use many common features e.g. partitioning, bitmap indexes etc.
I use to think that, partitioned view are no more supported by Oracle. But I can see that it works. I created 3 tables TEMP1, TEMP2 and TEMP3, all with exact same structure (columns and indices). Then created a view TEMP_VIEW, which is like
select col1, col2, col3 .... from temp1
union all
select col1, col2, col3 .... from temp2
union all
select col1, col2, col3 .... from temp3Here are the query execution and plans
/* ----------------- 10g execution plan ----------------------- */
SQL> select * from temp_view where object_id=2620 and branch_cd = 'XYZ';
OWNER OBJECT_NAME SUBOBJECT_NAME OBJECT_ID DATA_OBJECT_ID
OBJECT_TYPE CREATED LAST_DDL_ TIMESTAMP STATUS T G S BRANC
SYS LOADER_TRIGGER_INFO 2620
VIEW 18-FEB-09 16-APR-09 2009-02-18:10:07:57 VALID N N N XYZ
Elapsed: 00:00:00.29
Execution Plan
0 SELECT STATEMENT Optimizer=ALL_ROWS (Cost=2 Card=1 Bytes=132)
1 0 VIEW OF 'TEMP_VIEW' (VIEW) (Cost=2 Card=1 Bytes=132)
2 1 UNION-ALL (PARTITION)
3 2 TABLE ACCESS (BY INDEX ROWID) OF 'TEMP1' (TABLE) (Cost=2 Card=1 Bytes=132)
4 3 INDEX (UNIQUE SCAN) OF 'TEMP1_PK' (INDEX (UNIQUE)) (Cost=1 Card=1)
5 2 TABLE ACCESS (BY INDEX ROWID) OF 'TEMP2' (TABLE) (Cost=2 Card=1 Bytes=132)
6 5 INDEX (UNIQUE SCAN) OF 'TEMP2_PK' (INDEX (UNIQUE)) (Cost=1 Card=1)
7 2 TABLE ACCESS (BY INDEX ROWID) OF 'TEMP3' (TABLE) (Cost=2 Card=1 Bytes=132)
8 7 INDEX (UNIQUE SCAN) OF 'TEMP3_PK' (INDEX (UNIQUE)) (Cost=1 Card=1)
/* ----------------- 11g execution plan ----------------------- */
SQL> select * from temp_view where object_id=2620 and branch_cd = 'XYZ';
OWNER OBJECT_NAME SUBOBJECT_NAME OBJECT_ID DATA_OBJECT_ID
OBJECT_TYPE CREATED LAST_DDL_ TIMESTAMP STATUS T G S BRANC
PUBLIC GV$XML_AUDIT_TRAIL 2620
SYNONYM 16-NOV-09 16-NOV-09 2009-11-16:16:36:08 VALID N N N XYZ
Elapsed: 00:00:00.03
Execution Plan
0 SELECT STATEMENT Optimizer=ALL_ROWS (Cost=6 Card=3 Bytes=396)
1 0 VIEW OF 'TEMP_VIEW' (VIEW) (Cost=6 Card=3 Bytes=396)
2 1 UNION-ALL
3 2 TABLE ACCESS (BY INDEX ROWID) OF 'TEMP1' (TABLE) (Cost=2 Card=1 Bytes=102)
4 3 INDEX (UNIQUE SCAN) OF 'TEMP1_PK' (INDEX (UNIQUE)) (Cost=1 Card=1)
5 2 TABLE ACCESS (BY INDEX ROWID) OF 'TEMP2' (TABLE) (Cost=2 Card=1 Bytes=102)
6 5 INDEX (UNIQUE SCAN) OF 'TEMP2_PK' (INDEX (UNIQUE)) (Cost=1 Card=1)
7 2 TABLE ACCESS (BY INDEX ROWID) OF 'TEMP3' (TABLE) (Cost=2 Card=1 Bytes=102)
8 7 INDEX (UNIQUE SCAN) OF 'TEMP3_PK' (INDEX (UNIQUE)) (Cost=1 Card=1)Questions
1) I am expecting same behaviour on Oracle enterprise edition, will that be the case ?
2) On 10g, execution plan shows "UNION-ALL (PARTITION)", but on 11g it says, "UNION-ALL". What does that imply?
3) Which Oracle parameter can affect this behaviour? the old partition_view_enable parameter does not exist
4) If I go ahead and use this partitioned view, in which cases this can cause problems? At this point, it looks all good if I access the view using indexed columns (of the tables and all tables involved have exactly same indexes).
Thanks in advance
Billy Verreynne is an expert in this area and has been introducing people for years to 'partition views' and you can find many of his previous posts about how and when to use them (including example code) right here in these forums (most of them will be in the SQL and PL/SQL forum).
This feature has been around since Oracle 7 and the 7.3 document that details the info is still at
http://docs.oracle.com/cd/A57673_01/DOC/server/doc/A48506/partview.htm
Here is just one of his many other threads with more example code using five tables.
Table name in from clause
Similar Messages
-
Difference between Materialised view in 10g and 11g
Hi,
I am beginner . I want to know the difference between Materialized view between 10g and 11g. Is there any impact if the materialized view used in 10g gets upgraded to 11g ?
awaiting ur response.Please and ThanksIn addition to the documentation, you might want to look at the blog of Alberto Dell'Era:
http://www.adellera.it/blog/
Alberto writes quite a bit about materialized views, including this important change in 11GR2:
http://www.adellera.it/blog/2009/11/03/11gr2-materialized-view-logs-changes/ -
NVL in view: discrepancy between 10G and 11G
Hi,
I've discovered some discrepancy between 10G and 11G in a way how view deals with NVL-based column in a where clause.
Here are two examples:
*10G:*
Connected to:
Oracle Database 10g Release 10.2.0.4.0 - Production
SQL> create table test_nvl (null_column number);
Table created.
SQL> insert into test_nvl values (null);
1 row created.
SQL> commit;
Commit complete.
SQL> create view view_nvl as select nvl(null_column,0) null_column from test_nvl;
View created.
SQL> select * from view_nvl where null_column is not null and null_column = 0;
NULL_COLUMN
0
*11G*
Connected to:
Oracle Database 11g Release 11.2.0.1.0 - 64bit Production
SQL> create table test_nvl (null_column number);
Table created.
SQL> insert into test_nvl values (null);
1 row created.
SQL> commit;
Commit complete.
SQL> create view view_nvl as select nvl(null_column,0) null_column from test_nvl;
View created.
SQL> select * from view_nvl where null_column is not null and null_column = 0;
no rows selected
Does anyone know why it behaves differently?
I couldn't find any documentation regarding this.
Or I'm just missing something here.
ThanksBANNER
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
PL/SQL Release 11.2.0.2.0 - Production
CORE 11.2.0.2.0 Production
TNS for HPUX: Version 11.2.0.2.0 - Production
NLSRTL Version 11.2.0.2.0 - Production
CREATE TABLE test_nvl (null_column NUMBER);
INSERT INTO test_nvl
VALUES (NULL);
COMMIT;
CREATE VIEW view_nvl
AS
SELECT NVL (null_column, 0) null_column FROM test_nvl;
SELECT *
FROM view_nvl
WHERE null_column IS NOT NULL AND null_column = 0;
NULL_COLUMN
0 -
Is there any difference between 10g and 11g M Views?
Hi,
I need to give a demo on and working examples of materialized views. The requirement is this: Master tables are in a 10g R2 DB, MV is in a 11g.
I just create a DB Link in 11g to point to the 10g DB and then create the MV in 11g.
Will there be any problems creating a 11g MV using 10 Master tables?
My question is are there any significant differences between 10g and 11g MViews??
Thanks & Regards,
Channa.You have to be careful about your versions. 10g could be 10.1 or 10.2 11g could be 11.1 or 11.2
I wouldn't have an 11.2 database with a database link against a 10.1 database.
In fact, even with 10.2, I would try to ensure that I have a "high patchset" (10.2.0.4 or 10.2.0.5) although, in theory, 10.2.0.1 should also work.
See Oracle Support article
Client / Server / Interoperability Support Between Different Oracle Versions [ID 207303.1]
Hemant K Chitale -
Running Oracle database 10g and 11g on same 5 RAC nodes
Hello Gurus,
Could any body throw light if I can install and sucessfully run Oracle database 10g and 11g on the same Oracle RAC installation setup.My setup is below
Number of nodes-5
OS- windows 2003 or RHEL5
storage- DELL EMC SAN
Clusterware- oracle version11g
File system-Automatic storage management(ASM)
After I successfully setup clusterware,ASM on the nodes,I would want to install 11g database on all 5 nodes .
Then Install 10g database on only 3 of the nodes using the same clusterware.
What are your views on the same.
Also FYI... as per metalink node 220970.1(RAC: Frequently Asked Questions) one can do such a setup.
what iam looking for is practical experience if anyone has implemented this in production system,if yes any issues faced and how tough it is to support.
Thanks,
ImtiyazYou could run an 11g database and 10g database on the same cluster as long as you use Clusterware 11g.
The administration aspect will drastically change according to the platform you run on. As of now, it appears you don't know whether it will be Linux or Windows.
It would be practical to support the same database release. -
Difference in select for update of - in Oracle Database 10g and 11g
Hi, I found out that Oracle Database 10g and 11g treat the following PL/SQL block differently (I am using scott schema for convenience):
DECLARE
v_ename bonus.ename%TYPE;
BEGIN
SELECT b.ename
INTO v_ename
FROM bonus b
JOIN emp e ON b.ename = e.ename
JOIN dept d ON d.deptno = e.deptno
WHERE b.ename = 'Scott'
FOR UPDATE OF b.ename;
END;
/While in 10g (10.2) this code ends successfully (well NO_DATA_FOUND exception is raised but that is expected), in 11g (11.2) it raises exception "column ambiguously defined". And that is definitely not expected. It seems like it does not take into account table alias because I found out that when I change the column in FOR UPDATE OF e.empno (also does not work) to e.mgr (which is unique) it starts working. So is this some error in 11g? Any thoughts?
Edited by: Libor Nenadál on 29.4.2010 21:46
It seems that my question was answered here - http://stackoverflow.com/questions/2736426/difference-in-select-for-update-of-in-oracle-database-10g-and-11gThe behaviour seems like it really is a bug and can be avoided using non-ANSI syntax. (It makes me wonder why Oracle maintains two query languages while dumb me thinks that this is just a preprocessor matter and query engine could be the same).
-
How to Install oracle 10g and 11g on aix 6.1
Can we install oracle 10g and 11g Enterprise Editions on IBM aix 6.1 ? If so how
Chetan
Edited by: chetan0926 on Jan 11, 2012 2:56 AMHi;
Can we install oracle 10g and 11g Enterprise Editions on IBM aix 6.1 ? If so how Yes you can,both version is certified
I agree Sybrand, Please check installation guide. All your questions will be answered in it
http://www.oracle.com/pls/db102/homepage
http://www.oracle.com/pls/db112/homepage
Also see:
Oracle Database on Unix AIX,HP-UX,Linux,Mac OS X,Solaris,Tru64 Unix Operating Systems Installation and Configuration Requirements Quick Reference (8.0.5 to 11.2) [ID 169706.1]
Regard
Helios -
Differences between Oracle Discoverer 10g and 11g .
we would like to know if they are any differences between Oracle Discoverer 10g and 11g and any issues with 10g that are overcome in 11g.
Please make us aware of any merits in going for 11g over 10g.
apps version 11.5.10.2
RegardsPlease see these links for the list of new features, bug fixes, certification, and installation of Discoverer 11g on 11i instance.
Discoverer 11.1.1.4 Certified with E-Business Suite
http://blogs.oracle.com/stevenChan/2011/02/discoverer_11114_ebs.html
EBS Sysadmin Primer: Oracle BI Discoverer 11gR1
http://blogs.oracle.com/stevenChan/2010/08/discoverer_11gr1_primer.html
Oracle Business Intelligence Discoverer 11g
http://www.oracle.com/technetwork/developer-tools/discoverer/overview/index.html
Oracle Business Intelligence Discoverer 11g documentation
http://www.oracle.com/technetwork/developer-tools/discoverer/documentation/index.html
Thanks,
Hussein -
Important differences between oracle 10g and 11g
Hi friends, can anyone tell me (pointwise) what are the major (and minor) differences between Oracle 10g and 11g.
Please point me to some documents if possible.
Thanks in advanceThe name of the link says it all: "top_features."
In short it is Oracle's list of what they have for marketing and sales reasons designated "top features."
It is not intended to be, and is not, a complete list of features. Often the features Oracle does not
talk about are the most important.
Let me give you some examples. I have never seen Oracle announce DBMS_XPLAN as a new feature
yet you should not run an explain plan without it. Neither have I ever seen Oracle announce the new
NO_DATA_NEEDED predefined exception. I have listed literally hundreds of new features you will not
find in Oracle's new features docs.
I did a presentation at OpenWorld this year as part of the unconference titled "New Features in
Database 11gR2 that Oracle will not announce." It was easy to prepare a one hour presentation with
little fear of being proved incorrect. As I turned out only one of the features I presented was mentioned
by Oracle.
You can find the presentation slides here:
http://www.morganslibrary.org/pres/oow09_ucnf.pdf -
Difference between oracle bpm 10g and 11g
Newbie: I am trying to understand 10g. The basic questions I have is
1)What is the difference between 10g and 11g?
2)What is the infrastructure & skillset needed for me to do implementation in 10g?
3)How is migration from 10g to 11g is accomplished?
Any resource links that would help me to get started with 10g would be appreciated.
ChaitanyaHi,
Please follow the below mentioned link to find your answer.
Re: Main differences between oracle bpm 10.3 vs 11g
Migration from ALBPM 5.7 to BPM 11g
Bibhu -
Diff between oracle 10g and 11g
Can any one could tell me what is the main diff between oracle 10g and 11g ?
Thanks in Advance
VenkatHi,
You can read
http://www.oracle.com/technetwork/articles/sql/index-082320.html
http://www.oracle.com/technetwork/articles/sql/index-099021.html
Anand -
Difference- Architenture of 10g and 11g
Hi All,
Pls just let me know is ther any huge difference between architecture of Oracle 10g and 11g ?.
Kindly suggest in very brief or just yes/no.
Thanks,Nimish Garg wrote:
There r no major difference b/w 10g & 11g Architecture
check this link out for new features of 11g
http://www.dba-oracle.com/oracle11g/oracle_11g_new_features.htm
I'm sure I've mentioned before about being careful when using that site to demonstrate answers. It's notoriously lacking information and only gives partial answers, mainly because it's trying to get people to purchase the books it sells for complete answers.
Far better would be to link to Oracle's own resources... e.g.
http://www.oracle.com/technology/pub/articles/oracle-database-11g-top-features/index.html -
Hi,
Is it fine to install oracle 10g and 11g on RHEL 6?
Please guide!!
thanksHi;
Is it fine to install oracle 10g and 11g on RHEL 6?Its not certified as mention. But if you want to make installation on that release see Tim's site:
http://www.oracle-base.com/blog/2011/02/13/oracle-11gr2-on-oracle-linux-6/
Regard
Helios -
Diffrence between OBIEE 10g and 11g Architecture
Hi
Please help me by providing either the differences between the OBIEE 10g and 11g Architecture or a pointer/link.
ThanksHi,
There are some!!
Check here;
http://www.rittmanmead.com/obiee11g/
http://www.biconsultinggroup.com/images/VideoAlbum/WhitePapersFAQ10-31-10.pdf
http://blogs.oracle.com/robreynolds/2010/12/security_in_obiee_11g_part_1.html
http://blogs.oracle.com/robreynolds/2010/12/security_in_obiee_11g_part_2.html
This will give an indication of all the changes.
Cheers,
Daan Bakboord
http://obibb.wordpress.com -
Golden Gate 32bit for Oracle 10g and 11g
Does oracle released Golden Gate 32bit for Oracle 10g and 11g, i could not able to find out 32bit http://edelivery.oracle.com or OTN.
Thanksnever mind, i was able to download from e-delivery.
Maybe you are looking for
-
Can I get a refund or better yet an exchange on a download that I did not want
I bought and downloaded Chris Cornell live "clean" version C.D. by mistake I wanted to download the "uncut, explicit" version instead. I did not know there were 2 choices on the same C.D. Will apple exchange this or am I stuck with it?
-
Is there any event will fire on tabkey.
I wanto set focus when user navigates from one ui element to another ui element using 'tabkey' from the keyboard. i get to know we can use view->request_focus_on_view_elem( lv_v_elem ). this can be code in modifyview. but when i use 'tabkey' modifyvi
-
Possible to create "multiple" "snapshot" folders in Photo app?
I mastered the whole "Hold both buttons to take a screenshot" idea. However, all screenshots are saved in one "saved pictures" folder under the "albums" tab. Any way to make multiple folders? Say, by date or website or.... anything? I know I can make
-
SAP mail not received for transfer order errors in background
Hi All, We need to set up automated mails to SAP inbox in case there is any error during automatic TO creation in the background. The customizing for this has been done. Now in OMKX for MAIL messages we have two options, either tick the document user
-
I am not able to display or change the file after deleting the file
Hi All, I am checking in the document to content category while creating the DIR. I tried to delete the file on my desktop and after i am unable to open the file in CV02N,It gives the below error: Error while executing "C:\ Firdosi\Desktop\gg.txt" I