Oracle 10g ROWNUM issue

Hi --
I have the below query which takes about 30 seconds(if rownum used) on 10g and 0.2 (or less) seconds on 9i...stats are up-to-date. 10g results comes back within < 0.2 seconds if i take the rownum out from the query but the issue is when i use rownum. 9i with our with rownum comes back within <0.2 secs.
10g - takes 30 secs for this query whereas 9i takes < 0.2 secs -- WITH ROWNUM
SELECT gmdb_id, lev FROM (SELECT v.gmdb_id, v.lev FROM
(SELECT gmdb_id, parent_id, LEVEL lev, create_date
FROM NODE_TREE WHERE LEVEL = 1 AND NODE_DEF >= 2 AND node_type < 3 START WITH parent_id = 207187 CONNECT BY parent_id=PRIOR gmdb_id) v,NODE_ATTRIBUTES NAttribs WHERE NAttribs.gmdb_id = v.gmdb_id AND NVL(PUBLISH_LOCATION_ID,0) <= 0
AND DISABLED = 0 AND NVL(HIDE_FROM_PUBLISH,0) = 0 AND TO_DATE(TO_CHAR((SYSTIMESTAMP AT TIME ZONE 'GMT'),'mm/dd/yyyy HH24:MI:SS'),'mm/dd/yyyy HH24:MI:SS') BETWEEN PUBLISH_START_TIME AND PUBLISH_STOP_TIME ORDER BY sort_order DESC, v.CREATE_DATE DESC, v.gmdb_id DESC) WHERE ROWNUM < 201
---10g WITHOUT ROWNUM comes back <0.2 secs---any know issues or any suggestions as what the issue could be with and without using rownum
SELECT v.gmdb_id, v.lev FROM
(SELECT gmdb_id, parent_id, LEVEL lev, create_date FROM NODE_TREE
WHERE LEVEL = 1 AND NODE_DEF >= 2 AND node_type < 3 START WITH parent_id = 207187 CONNECT BY parent_id=PRIOR gmdb_id) v, NODE_ATTRIBUTES NAttribs WHERE NAttribs.gmdb_id = v.gmdb_id
AND NVL(PUBLISH_LOCATION_ID,0) <= 0 AND DISABLED = 0
AND NVL(HIDE_FROM_PUBLISH,0) = 0 AND TO_DATE(TO_CHAR((SYSTIMESTAMP AT TIME ZONE 'GMT'),'mm/dd/yyyy HH24:MI:SS'),'mm/dd/yyyy HH24:MI:SS') BETWEEN PUBLISH_START_TIME AND PUBLISH_STOP_TIME ORDER BY sort_order DESC, v.CREATE_DATE DESC, v.gmdb_id DESC

Hash join in 10g compared to nested loop in 9i.
sort(ORDER BY STOPKEY)
--10g plan cost 26470 - below is the diff in both the plans---
MAT_VIEW ACCESS(FULL) GMDB.NODE_ATTRIBUTES     ANALYZED     17767     219     7227                         NVL("PUBLISH_LOCATION_ID",0)<=0 AND NVL("HIDE_FROM_PUBLISH",0)=0 AND "PUBLISH_START_TIME"<=TO_DATE(TO_CHAR(SYSTIMESTAMP(6) AT TIME ZONE 'GMT','mm/dd/yyyy HH24:MI:SS'),'mm/dd/yyyy HH24:MI:SS') AND "PUBLISH_STOP_TIME">=TO_DATE(TO_CHAR(SYSTIMESTAMP(6) AT TIME ZONE 'GMT','mm/dd/yyyy HH24:MI:SS'),'mm/dd/yyyy HH24:MI:SS') AND "DISABLED"=0
-9i plan cost 190 - used nested loop

Similar Messages

  • Oracle 10g Installation issue on Windows 7

    Hi,
    I tried to install Oracle 10g downloaded from the below link on my laptop which runs in Windows 7.
    http://www.oracle.com/technetwork/database/10204-winx64-vista-win2k8-082253.html
    The Oracle version is 10g release 2 for windows 7. I got this DB version no. for Windows 7 from this forum only. But still, I got the error message stated below and unable to install 10g.
    ------------------------------------------------------ Error --------------------------------------------------------------------------
    Starting Oracle Universal Installer...
    Checking installer requirements...
    Checking operating system version: must be 5.0, 5.1, 5.2 or 6.0 . Actual 6.1
    Failed <<<<
    Exiting Oracle Universal Installer, log for this session can be found at C:\Program Files (x86)\Oracle\Inventory\logs\installActions2010-10-22_07-37-48AM.log
    Please press Enter to exit...
    ------------------------------------------------------ Error End -------------------------------------------------------------------
    Could you please let me know how I can fix this issue? Or is there any other oracle 10g release/patch to fix this issue? I need to install only Oracle 10g and not 11g.
    Also, I need to install Oracle Forms 10g too.
    It would be great if you could guide me on installing these two softwares in my laptop.
    Your help will be very much appreciated.
    Thanks,
    Arun
    Edited by: 804404 on Oct 22, 2010 7:52 AM

    Welcome to the forums !
    This issue has been discussed many times before. Pl use the search feature. The only versions supported in Win 7 (Professional or higher) are 10.2.0.5 and 11gR2. 10.2.0.5 is only available on My Oracle Support, while 11gR2 can be downloaded for free from http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html
    Re: Oracle for Windows 7
    Re: which version of oracle works on windows 7
    HTH
    Srini

  • Symantec & Oracle 10g Compatibility issues

    Hi all,
    Recently i had virus attack on two of my database servers running oracle 10g. one is running on xp and the other on server 2003 r2.
    i cleaned the viruses applied windows patches and then installed symantec endpoint protection 11.
    after installing this teh system started crashing givin bsd.
    in the xp machine i did a bit of r&d and found out that there was a problem with oracle and symantec together.
    then i unsinstalled symantec made everything ok with the db and stopped db services and installed symantec back
    this worked and sytem was up and running again
    but the problem still continues with the windows server 2003
    as soon as i uninstalled oracle the system crashed and now its not starting.
    are there any compatibility issues between symantec and oracle 10g?
    or something should be taken care on the oracle server before installing symantec?
    Any suggestions or experience would really help.
    Regards
    Deepak

    Hi,
    I guess the problem is with Symantic and the Virus .
    As I know there is no direct ill-impact upon Oracle and Symantic together.
    There might be another cause... So some more R&D :)
    Edited by: The Human Fly on Jan 25, 2010 1:12 AM

  • Oracle 10g performance issues

    Hi,
    We were using Oracle 9i in Solaris 5.8 and it was working fine with some minor performance issues. We formatted the Solaris server with new Solaris 5.10 and installed Oracle 10g.
    Now we are experiencing some performance issues in Oracle 10g. This issue is arising when using through Websphere 5.1.
    We have analyzed the schema, index is rebuild, SGA is 4.5 GB, PGA is 2.0 GB, Solaris RAM is 16 GB. Also we are having some Mat Views (possibly this may cause performance issues - not sure) due to refresh.
    Also I have changed some parameters in init.ora file like query_rewrite = STALE_TOLERATED, open_cursors = 1500 etc.
    Is is something due to driver from which the data is accessed. I guess it is not utilizing the indexes on the table.
    Can anyone please suggest, what could be the issue ?

    <p>There are a lot of changes to the optimizer in the upgrade from 9i to 10g, and you need to be aware of them. There are also a number of changes to the default stats collection mechanism, so after your upgrade your statistics (hence execution paths) could change dramatically.
    </p>
    <p>
    Greg Rahn has a useful entry on his blog about stats collection, and the blog al,so points to an Oracle white paper which will give you a lot of ideas about where the optimizer changes - which may help you spot your critical issues.
    </p>
    <p>Otherwise, follow triggb's advice about using Statspack to find the SQL that is the most expensive - it's reasonably likely to be this SQL that has changed execution plans in the upgrade.
    </p>
    Regards
    Jonathan Lewis
    http://jonathanlewis.wordpress.com
    http://www.jlcomp.demon.co.uk

  • Oracle 10g Speed issue

    Hi.
    1. I am using Oracle 10g Enterprise Edition.
    2. on Windows Xp SP2.
    3. System configuratoin are: Intel Core2 Due 2.20Ghz, 512MB ram.
    But after installing Oracle 10g on the above mentioned system, the speed of my system gradually down/reduced.
    How we can set/fix this issue/problem.
    Regards!

    Did you install software only or created a sample database as well?
    Just installing the software won't make it slower. If you have created a database, how much SGA have you configured for this database?
    512MB RAM is definitely on lower side considering you are running Oracle 10g database and (some) other applications along with that.

  • Oracle 10g performance issue

    Hi all,
    In sunfire v890 we have installed oracle 10g release 2 on solaris 10.
    prstat -a command shows :
    NPROC USERNAME SIZE RSS MEMORY TIME CPU
    105 root 9268M 6324M 20% 1:21:57 0.4%
    59 oracle 24G 22G 71% 0:04:33 0.1%
    2 nobody4 84M 69M 0.2% 0:11:32 0.0%
    2 esbuser 13M 9000K 0.0% 0:00:46 0.0%
    1 smmsp 7560K 1944K 0.0% 0:00:00 0.0%
    4 daemon 12M 7976K 0.0% 0:00:00 0.0%
    and top utility shows :
    last pid: 8639; load avg: 0.09, 0.09, 0.09; up 2+06:05:29 17:07:50
    171 processes: 170 sleeping, 1 on cpu
    CPU states: 98.7% idle, 0.7% user, 0.7% kernel, 0.0% iowait, 0.0% swap
    Memory: 32G phys mem, 22G free mem, 31G swap, 31G free swap
    therefore from prstat we come to know that memory used by oracle is 71%
    where as top says 31.25% used.....
    which one is true in this scenario.....
    shall we go ahead in trusting top utility????
    Advance thanks to you.

    Hi darren
    The main thing is,, prstat -a command showing oracle
    user occupied 70%.In top utility showing 22gb memory
    free out of 32 gb.That means 10gb was occupied by all
    users.In percentage calculation its comes
    31.25%...i.e top shows all users occupied only
    31.25%Right. That's all memory in use, correct? From your first message I thought you meant it said that was the amount used by Oracle.
    It's easy to calculate total memory in use.
    It's hard to calculate memory in use by a subset of processes (perhaps those owned by a particular user).
    but prstat -t command shows 70% occupied by oracle.
    which one i want to believe??????The prstat command showing memory in use by a user will be incorrect because it does not calculated shared pages properly.
    As far as I am aware, 'top' has no similar display.
    Darren

  • Oracle 10g http issue. always ask for XDB and APEX password

    As i m uses oracle 10g express edition, it ask for XDB and Apex password frequently.
    i changed the port from 8080 to 8181 but still same problem.
    Any solution?

    If you wish to enable anonymous access to the ML DB repository, the following code creates the "<allow-repository-anonymous-access>" element if it is missing, or updates it if it is already present in the xdbconfig.xml file.
    CONN sys/password AS SYSDBA
    SET SERVEROUTPUT ON
    DECLARE
    l_configxml XMLTYPE;
    l_value VARCHAR2(5) := 'true'; -- (true/false)
    BEGIN
    l_configxml := DBMS_XDB.cfg_get();
    IF l_configxml.existsNode('/xdbconfig/sysconfig/protocolconfig/httpconfig/allow-repository-anonymous-access') = 0 THEN
    -- Add missing element.
    SELECT insertChildXML
    l_configxml,
         '/xdbconfig/sysconfig/protocolconfig/httpconfig',
         'allow-repository-anonymous-access',
         XMLType('<allow-repository-anonymous-access xmlns="http://xmlns.oracle.com/xdb/xdbconfig.xsd">' ||
         l_value ||
         '</allow-repository-anonymous-access>'),
         'xmlns="http://xmlns.oracle.com/xdb/xdbconfig.xsd"'
    INTO l_configxml
    FROM dual;
    DBMS_OUTPUT.put_line('Element inserted.');
    ELSE
    -- Update existing element.
    SELECT updateXML
    DBMS_XDB.cfg_get(),
    '/xdbconfig/sysconfig/protocolconfig/httpconfig/allow-repository-anonymous-access/text()',
    l_value,
    'xmlns="http://xmlns.oracle.com/xdb/xdbconfig.xsd"'
    INTO l_configxml
    FROM dual;
    DBMS_OUTPUT.put_line('Element updated.');
    END IF;
    DBMS_XDB.cfg_update(l_configxml);
    DBMS_XDB.cfg_refresh;
    END;
    /

  • Oracle 10g Installation issue

    While Installing Oracle 10g, I get the following warning
    Checking Network Configuration requirements ...
    Check complete. The overall result of this check is: Failed <<<<
    Problem: The install has detected that the primary IP address of the system is DHCP-assigned.
    Recommendation: Oracle supports installations on systems with DHCP-assigned IP addresses; However, before you can do this, you must configure the Microsoft LoopBack Adapter to be the primary network adapter on the system. See the Installation Guide for more details on installing the software on systems configured with DHCP.
    ========================================================
    When I ignored this warning and proceeded with the installation tnsnames.ora was not getting created.
    Please help on this.

    Hi,
    You need to configure the Loop Back Adapter on your system, Since ORACLE does not support the dynamic IP Address. Do the Loop Adapater the Problem will be solved.
    Refer :-
    http://youngcow.net/doc/oracle10g/install.102/b14316/reqs.htm#BABGCEAI
    Check for "Installing a Loopback Adapter"
    - Pavan Kumar N

  • Oracle 10g connection issue..

    Hi ,
    I have oracle 10g installed on one unix box and i need to connect to this oracle 10g from another unix box
    using the sqlplus client version 9.2.0.7.0.
    When i try to connect using sqlplus 9.2.0.7.0 i am not getting any response.
    is it possible to connect to oracle10g using sqlplus 9.2.0.7.0?
    Thanks.

    Zymson wrote:
    I have oracle 10g installed on one unix box and i need to connect to this oracle 10g from another unix box
    using the sqlplus client version 9.2.0.7.0.
    When i try to connect using sqlplus 9.2.0.7.0 i am not getting any response.You failed to provide any meaningful information in order to diagnose the problem.
    I suggest that you start off with some basic tests first.
    1. Ping
    Can you ping the remote server? On the local Unix box, use the dotted IP address of the remote Unix box and determine if it responds. E.g.
    ping <IP_ADDRESS>
    2. Hostname resolution
    Ideally you want to use the hostname (instead of dotted IP) of remote Unix box. Determine if the local Unix box resolves the remote Unix box's hostname. E.g.
    ping <HOSTNAME>
    3. Oracle port connectivity
    Next you need to test if the TCP port used by the Oracle Listener on that remote Unix box is reachable from the local box (and not firewalled for exampled). Telnet into this port (if the connection is accepted, press enter a few times and the telnet connection will be terminated by the listener). E.g.
    telnet <HOSTNAME> 1521
    4. Test SQL*Plus connectivity
    Once you've established that connectivity to the remote Listener is working, you need to test the TNS connection string and ensure that the connection parameters (such as ORACLE SID) that is passed to the Listener is correct. E.g.
    sqlplus scott/tiger@"(DESCRIPTION= (ADDRESS= (PROTOCOL=TCP)(HOST=<HOSTNAME>)(PORT=1521)) (CONNECT_DATA= (SID=<ORACLE_SID>) (SERVER=dedicated)))"
    Once all ths is working, should you update the local Unix box's tnsnames.ora file with the TNS connection string and use that TNS alias for connecting via SQL*Plus.
    If any of these steps do not work, post the full details of the step PLUS the actual error information (error codes and error messages).

  • ORACLE 10g commit issue.

    Greetings,
    this is Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 accessed via an OCI-7 application.
    OS is a SUSE LINUX Enterprise Server 9 (i586).
    I encountered the following issue:
    session A is connected to ORACLE (OCI-7 application)
    and
    session B is connected to ORACLE (OCI-7 application).
    Session A changes a column value from 50 to 42 and commits.
    Session B sees the changed value: 42.
    Session C new connects to ORACLE (OCI-7 application).
    Session C **does not** see the changed value, it still sees 50.     
    Session D new connects to ORACLE (sql-plus application).
    Session D **does not** see the changed value, it still sees 50.     
    I'm very puzzled and have no explanation for this case.
    I **cannot** repeat the issue.
    The application is years old, is very often used and issues like described above are discovered immediately.
    Any comment, hint or whatsoever on this issue, particularly on how such a situation possibly could be produced, would be very much appreciated.
    Thanks for your time
    Wolf
    Edited by: grossbau on Feb 4, 2012 2:08 PM
    Edited by: grossbau on Feb 4, 2012 3:32 PM
    Edited by: grossbau on Feb 4, 2012 3:56 PM

    What ever you are saying (not proof) is not possible, never...
    Chances are :
    1.Session C/D are not connecting to the right database.
    2.Session C/D are not query the commited schema.table.
    3.Session C/D are query the Materialized view(s), which needs refresh.
    4.Session A has not committed.
    Just double check your issue/application. There is no difference either you are using OCI application or I / anyone uses sqlplus.
    Regards
    Girish Sharma
    Edited by: Girish Sharma on Feb 4, 2012 10:20 PM
    Removing below line as per correction made by Pierre.
    Oracle's thumb rule is "Commited Data is visible to all/any/new/existing session(s) immediately".

  • Oracle 10g RAC issue

    Hi,
    I have been able to install oracle 10gR2 clusterware on Solaris 10 successfully on node1.
    However, on node2 if failed. I may be doing something wrong in the installation configuration that is causing node2 to fail. I will expolain what I did.
    I configured a raw disk partition for data files and a Unix file system for the oracle cluster home. Both node1 and node2 can access raw disk and shared file system for CRS home.
    Does anyone know if a single oracle cluster home can be shared between the two nodes?
    or should I install two seperate oracle cluster home for each node?
    The installation documentation didn't say anything. However, I am experiencing reboot on node2 once the shared disk is mounted. I was thinking if the shared mount point could cause the node2 to reboot.
    Thanks for your comments,
    Amir

    Thanks for your reply Salman,
    In fact we have SAN disks according to our system admin and I already passed the precrs check see below:
    -bash-3.00$ ./runcluvfy.sh stage -pre crsinst -n node01,node02
    Performing pre-checks for cluster services setup
    Checking node reachability...
    Node reachability check passed from node "node01".
    Checking user equivalence...
    User equivalence check passed for user "oracle".
    Checking administrative privileges...
    User existence check passed for "oracle".
    Group existence check passed for "oinstall".
    Membership check for user "oracle" in group "oinstall" [as Primary] passed.
    Administrative privileges check passed.
    Checking node connectivity...
    Node connectivity check passed for subnet "192.168.1.0" with node(s) node02,node01.
    Node connectivity check passed for subnet "10.1.0.0" with node(s) node02,node01.
    Node connectivity check passed for subnet "10.1.4.0" with node(s) node01.
    Suitable interfaces for the private interconnect on subnet "192.168.1.0":
    node02 ce0:192.168.1.2
    node01 ce0:192.168.1.1
    Suitable interfaces for the private interconnect on subnet "10.1.0.0":
    node02 eri0:10.1.4.202 eri0:10.1.4.44
    node01 eri0:10.1.4.43
    Regards

  • Oracle 10g database issue

    i have deleted the pfile how to create pfile from spfile

    user11867336 wrote:
    plese help meGood grief! It was only 4 minutes from you original post. This is not a chat room. And it's the weekend. (and in the U.S., a holiday weekend at that!).
    No one is paid to provide instant response. It's a forum (again, not a chat room) of volunteers from around the world. The guy with the information you seek could very well live 12 time zones away from you and have just shut down as you were posting. I never look for a response in less that 24 hours, and allow for holidays and wekeends at that.
    Not to mention yours is a simple documentation question that could have been answered in about 90 seconds had you gone to the documentation library at tahiti.oracle.com and used the fine search capabilities there.
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_6008.htm#i2072768

  • Oracle 10g Migration

    Oracle server version :- 10g
    Oracle client version :- 9i
    BEA Weblogic Version :- 8.1SP5
    Actually we are migrating the database from Oracle 9i server to Oracle 10g server.
    issues :- in 10g very Poor performance compare to 9i
    Actually we don't exactly where is problem occured, wheather it's occured in BEA Weblogic or Oracle database
    plz help how to solve this problem

    SUN_RR wrote:
    Oracle server version :- 10g
    Oracle client version :- 9i
    BEA Weblogic Version :- 8.1SP5
    Actually we are migrating the database from Oracle 9i server to Oracle 10g server.
    issues :- in 10g very Poor performance compare to 9i
    You should consult with Oracle about this. If nothing else has changed except the database version, why would it be the fault of Java or BEA?
    Actually we don't exactly where is problem occured, wheather it's occured in BEA Weblogic or Oracle database
    No one else can guess based on the little information you've provided. Better sort that out. Profile both and see where the time is being spent.
    plz help how to solve this problemBe scientists and get some data.
    %

  • Could not install oracle 10g on windows 7

    Hi All,
    I downloaded the Oracle 10g version to install in my laptop.
    OS version is windows 7.
    When i run the setup file it giving error like windows version supported is 5.1,....6.0 Actual version 6.1 and the installation fails.
    please advice me how i can install?
    Regards,
    Arun Kumar

    Pl use the search option to find other threads like this - Re: Oracle 10g Installation issue on Windows 7
    10g and Windows 7 has been discussed many times on these forums - http://forums.oracle.com/forums/search.jspa?threadID=&q=10g+AND+Windows+AND+7&objID=f64&dateRange=thisyear&userID=&numResults=15&rankBy=10001
    HTH
    Srini

  • Oracle 10g RAC using ASM - Storage Issue

    I’ve an issue related to Oracle 10g RAC.
    I’ve 2 node cluster each being Dell 2850 Server with RHEL 4.0
    I’ve EMC CX300 SAN storage with following partitions
    /orasoft     10 Gb          OCFS2 File system
    /oracrs          2 Gb          OCFS2 File system
    /orabackup      100 Gb          OCFS2 File system
    The datafiles are on ASM which is not directly visible in OS.
    I’ve common Oracle Home installed in /orasoft/db_1 which is shared by both nodes in cluster.
    I’ve faced an issue recently related to EMC storage.
    The /orasoft partition displays 1.4 Gb space available using df command.
    With both nodes sharing the common Oracle Home (/orasoft/db_1), when ever I try to touch a file I get an error as No Space left on device. I’m unable to start any service with the same reason.
    Is this setup correct ??
    Can anyone help me with this storage issue ??

    Need a clarification here...what do you mean by "Storage System"...do you mean a server/node or the SAN storage system. If you are referring to a server/node's local storage, then it would NOT be possible for use by RAC, since the disk space has to be shared among the nodes.
    Here is what you can do:
    - Create two partitions/devices (for example Disk_1 and Disk_2) in the SAN storage
    - Create a ASM disk group which would mirror Disk_1 to Disk_2.
    Again, please note that the partitions have to be visible and be accessible read/write from both the nodes/servers.
    HTH
    Thanks
    Chandra Pabba

Maybe you are looking for

  • OEM agent deployment : Status=255

    Hi, I am deploying OEM Agent 10.2.0.2.0 on Linux (32-bit). As first installation was failed because of permission issue, I tried to reinstall it. I ended with this error : Initializing Java Virtual Machine from /tmp/OraInstall2007-02-26_03-45-43PM/jr

  • Why have I lost the info of  timezone (Timestamps with Timezone )

    I have been trying to get timestamps with timezones working in my Java application, but I don't seem to get the data I expect back from the JDBC driver my field type is Timestamps with Timezone ,in the database,I saw the info of (12-DEC-06 01.12.12.1

  • Connection between class, WPF-controls and parameters

    Hello, How do I show an instance of a class on my form and how do I connect this instance to my parameters? I have defined a class VV and added validation to it (I intend to use this class im multiple projects): public class VV private Int64 id; priv

  • Time machine says that requires 426GB on a 120GB macbook!

    Hi there, does anybody know why I am having the problem of time machine saying that it needs 426GB on a 120GB machine? I initially had the problems with "error 11" and gave up trying to fix it; so I re-formatted the time machine disk thinking I would

  • Java VM Please help, Cannot remove and cannot Reinstall.

    hello, I hope somebody can help me out here, I'm at my wits end. First of all I have xp pro file system NTFS, I have AOL DSL Broad band. I have attempted to get my Java Download DAYS ago and something went terribly wrong. After the download I noticed