Tuning Issue between 2 queries...

Hello ;
the first query is
select prog, at_pck.y(prog) z from (select distinct prog from x where stat = 'oracle');
execution time is like 0.1 sec
when i modify the query above like that;
select k.prog from (select distinct prog from x where stat = 'oracle') k where at_pck.y(k.prog)=1
execution time is longer than 2 sec
i thought second query is supposed to be faster than first query...but i was wrong and the second query was taking longer than the first query;
can someone explain me why the second query is slower than first one?
or is there any way of tuning second query?

Hi,
1) please format plans you post using tags
2) when posting plans, please include predicate information
3) if possible, also provide timings and cardinality feedback -- see forum's FAQ how to do that
Having said that, I think that one of two things may be happening here.
1 - both queries are performing equally, it's just that your SQL client is not fetching all rows, thus creating an impression
that 1st query works faster
2 - the first query could, in fact, be faster, if at_pck.y is not a deterministic functions. Usage of non-deterministic functions
in WHERE clause can have undesired side effects, like calling the function more times than necessary.
So I would suggest the following:
- change array_size to 5000 and see if it makes a difference for performance of the 1st query
- check how many times at_pck.y() is called in the 2nd query (e.g. by instrumenting the function's code to log messages to a special log table and commit autonomously)
- post all requested information from above (1-3) plus the code of at_pck here
Best regards,
  Nikolay
Edited by: Nikolay Savvinov on Jun 5, 2012 12:25 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

Similar Messages

  • Routing issue between Cisco Nexus and Cisco 4510 R+E Chassis

    We have configured Cisco Nexus 7K9 as core and Cisco 4510 R+E as access switches for Server connectivity.
    We are experiencing problem in terms of ARP learning and Ping issues between Cisco Nexus and end hosts.

    Hi,
    So you have N7k acting as L3 with servers connected to 4510?.
    Do you see the MAC associated with failing ARP in 4510?. Is it happening with all or few servers?. Just to verify if it is connectivity issue between N7k and 4510, you can configure an SVI on 4510 and assign address from same raneg (server/core range) and perform a ping.
    This will help narrow down if issue is between server to 4510 or 4510 to N7k.
    Thanks,
    Nagendra

  • Serious Sync issues between iTunes 8.0.2 and AppleTV 2.3

    Please Help,
    Everything was just wonderful until several weeks back when the AppleTV started having sync issues that seem to have degraded into oblivion. Rebooted everything, checked all software loads, tried many of the suggestions (no blocking network / firewall issues) and have even tried adding redundant port allows for any and all ports I could find going in / out of Apple TV. But to no avail there seems to be a bug that got introduced somewhere with the sync mechanisms.
    The Apple TV can purchase movies, download them fast to start playing, view youtube videos just fine and play all of the media great, So can my Mac and all media / iTunes functions work well it even syncs with my iPhone / iPods well.
    However... The only way I can get the AppleTV to sync is to reboot it, then it will sync some, iTunes will just get to a forever syncing with Apple TV state (which you have to stop), reboot AppleTV again, it will sync some more, until it stops, iTunes is stuck syncing forever with AppleTV again, repeat and rinse about 4 more times and you have it all synced.
    If there isn't anything to sync when AppleTV boots the Sync in iTunes just spins for ever. I actually left it for 4 days just to see if it was actually doing anything. Minimal Network IO and of course it never finished.
    If I stop the Sync with Apple TV in iTunes and then try to reinitiate it from iTunes I get the 3986 port error (which is bogus) unless there is some hidden setting somewhere in the OS that I can't find. And if there was a problem then why would it start and run when I boot the Apple TV.
    It just seems that all of a sudden things started going wrong with Sync with no real change other than 'software updates' .
    The only thing I haven't tried is to do a factory reset on the AppleTV which from what I have read doesn't really solve anything.
    So, please someone from Apple or someone with some detailed technical experience provide some guidance on whether there is a bug that got introduced, version issues between iTunes/AppleTV, or something else going that I haven't been able to figure out over the last 2 weeks.
    The only other unique things that may be different is that I have my iTunes library on an external drive (not on the internal drive). Does this many any difference?
    Thank You in advance to anyone that can help me get to the bottom of these issues. This started happening when I was totally sold on AppleTV and about to buy a second one.
    mmilford

    And it's good to know I'm not the only one with the problem too! I just cannot sync stuff from Mac to Apple TV without it locking up. It actually seems to lock the wifi also, meaning I have to quit iTunes, turn off the wifi and then turn it back on again. But as soon as I open iTunes, the same problem again...
    I've tried everything I can think of, searched all help articles, but cannot sort out this somewhat annoying problem.
    Message was edited by: Lee Nixon

  • Any known 'porting' issues between 8.2.2 and 9.0 ??

    Hi all,
    we are in the process of evaluating LS ES2 (9.0) and would like to know if there are any 'porting' issues between the two versions.   Asked another way, are there any issues in deploying a 8.2.2. LCA onto 9.0 ?
    Dan

    8.2 LCA's will run fine in 9.0 if they are just deployed into it.  But in 9.0 a new application model has been introduced, so in order to make changes to anything after you've migrated it you'll need to create an application and migrate your processes and resources into it.  You may want to take a look at the Leveraging Legacy Solution document available online.  Here's the link:  http://help.adobe.com/en_US/livecycle/9.0/workbenchHelp/help.htm?content=leveragingLegacy. html .
    Chris

  • Compatibility issue between your power management system and Windows 8.1

    I have purchased a new Lenovo Ideapad S410 and have this problem.
           Compatibility issue between your power management system and Windows
           It also gives a message "Your PC ran into a problem and needs to restart. We're just collecting some error info, and then we'll restart for you. (100% complete)
           If you'd like to know more, you can search online later for this error:
    VIDEO DXGKRNL FATAL ERROR
    Please help! My laptop is only 5 days old.

    What model do you have? Can you post your MTM or model name?
    Sometimes these messages are a false alarm.

  • File sharing issues between iMac G5 20"/Mac OS 10.5.8 and iBook G3 600mhz/Mac OS 10.4.9.

    Both Macs can copy files from each other using the AFP connection.  However, I cannot copy files to another Mac.  So when I try and copy a file from the iMac to the iBook, I get these series of messages:
    1) You May Need to enter the name and password for an administrator on this computer on this computer to change the item names "filename".
    2) The item "filename" contains one or more items  you do not have permission to read. Do you want to copy the items you are allowed to read?
    3) The operation cannot be completed because you do not have sufficient privileges for some of the items.
    I'm not given the prompt for name and password at any stage.
    When I try and copy from the iBook to the iMac, this is the only message I receive:
    The operation cannot be completed because you do not have sufficient privileges for some of the items.
    I'm not given the prompt for name and password at any stage.
    With the iMac, I have the permissions preferences set for my startup drive and external harddrives for Read and Write for all entries.  I can't do that on the iBook because it doesn't have those settings in the Sharing Preferences.
    Could the fact that both Macs use the same user/account name and password?  I never had this issue between my iBook and Power Mac G3 300mhz/Mac OS 10.2.8 when having the same name and password.
    All help is appreciated.  Thanks.
    Bill Rudloff

    I've done a little reading, and it has to do with under the hood stuff with the Login ID number.  I found how to change it on the iBook, but I can't figure it out on the iMac.  Ideally, I want them to both be 501.  So how do I sent the iMac in Mac OS 10.5.8?
    Bill Rudloff

  • How do I fix the compatibility issue between my iPhone 4S with iOS 7 and my Pioneer car stereo? There was no problem with iOS 6, but now I get a message saying "this device is not compatible" and so I can't use Netflix for example. How do I fix it?

    How do I fix the compatibility issue between my iPhone 4S with iOS 7 and my Pioneer car stereo? There was no problem with iOS 6, but now I get a message saying "this device is not compatible" and so I can't use Netflix for example. How do I fix it?

    This is a typical response from the manufacturer. Did you try the fix that Lawrence mentioned. When Apple or any other phone manufacturer update phone software, they have the latest Bluetooth installed. It is usually the problem with the radio manufacturer that they devices are using the older Bluetooth protocols. You can try this support document http://support.apple.com/kb/TS3581 and see if anything there helps, but generally it requires the radio manufacturer to update their firmware.

  • Why can't I use WebCT chat with my computer?  I get the 'spiral of death' every time I try to type in my chat.  I have a feeling it has to do with compatibility issues between Java and Tiger.

    Why can't I use WebCT chat with my computer?  I get the 'spiral of death' every time I try to type in my chat.  I have a feeling it has to do with compatibility issues between Java and Tiger.

    Hi Elizabeth,
    Do your Mac meet any of these requirements?
    http://www.wvnet.edu/services/webct/requirements.html
    From this it appears to be PC only!???
    http://sourceforge.net/projects/awebctcclient/files/Pancake%20%28it%20own%20proj ect%20now%29/Pancake%20Console%20V1.0.0/PancakeConsole-1.0.0-src.zip/download
    Can you provide any more info on which bersion or file you have?
    Can you tell us why you need this for your use?

  • Issues between power, usb and airport?

    Well, after having my new MacBook Pro for only a couple of weeks, I've come to the conclusion that there are some pretty weird issues between the power manager, usb bus and airport (and from what I've read here, are pretty widespread issues). First, every time I charge the battery, my Logitech MX laser mouse stutters and jumps all over the screen (trackpad works smoothly though). If I turn off airport, the mouse works smoothly again. When the battery is done charging, the mouse will work smoothly again. Second, every now and then (when the mouse isn't connected) the trackpad will start to stutter and jump all over the screen. When this happens, I've noticed that the graphics card is running slowly as well (expose stutters). Both of these issues can then be remedied by one of two actions, either plug something into a usb port, or turn off airport. I am also suffering from the missing first letter issue, which also seems to go away by disabling airport... So, since disabling airport most of the time is not an option, anyone care to take a guess as to how long it will take Apple to come up with a fix to these issues?

    TM does not backup to a networked drive in the same way as a directly connected drive. A networked drive requires the creation of a .sparsebundle disc image file that holds the actual backed up files. So when you shift from direct to networked connection TM actually makes a different backup. This is unrelated to the actual type of port connection. So there's really nothing you can do to have TM use one backup for each type of connection used in your situation.

  • VPD date issue between 10.1 and 10.2 databases

    I have uncovered an issue today with VPD against date fields. The issue came up at a client site on a 10.2 database. When I got back to the hotel and tried this on my own database, which is 10.1, I got no issue and everything worked ok.
    Therefore, I am asking if anyone is able to try out the following for me on different Oracle databases and platforms and let me know whether it worked for you or not. I'd like to compile a list of database versions and platforms on which the issue occurs.
    Step 1: create this table as a user
    CREATE TABLE TST_DATE AS (
    SELECT 1 PERSON_UID,
    Trunc(SYSDATE) BIRTH_DATE,
    To_Char(Trunc(SYSDATE), 'DD-MON-YYYY') CHAR_DATE,
    123456 TAX_ID,
    'Smith, Michael B.' FULL_NAME FROM dual);
    Step 2: grant select rights on the table
    GRANT SELECT ON TST_DATE TO PUBLIC;
    Step 3: switch your login to SYS and run this script:
    CREATE OR REPLACE FUNCTION F_CHECK_ITEM_TST(p_object_schema in varchar2, p_object_name varchar2)
    RETURN VARCHAR2 IS
    V_PREDICATE VARCHAR2(2000) := '1 = 2';
    BEGIN
    RETURN(V_PREDICATE);
    END F_CHECK_ITEM_TST;
    Step 4: As SYS, run this to grant access rights over the function
    GRANT EXECUTE ON F_CHECK_ITEM_TST TO PUBLIC;
    Step 5: As SYS, run this to enable the policy
    BEGIN DBMS_RLS.ADD_POLICY(
    OBJECT_SCHEMA => 'DRAKE',
    OBJECT_NAME => 'TST_DATE',
    POLICY_NAME => 'SecByTST',
    FUNCTION_SCHEMA => 'SYS',
    POLICY_FUNCTION => 'F_CHECK_ITEM_TST',
    STATEMENT_TYPES => 'SELECT',
    POLICY_TYPE => DBMS_RLS.DYNAMIC,
    SEC_RELEVANT_COLS => 'BIRTH_DATE',
    SEC_RELEVANT_COLS_OPT => DBMS_RLS.ALL_ROWS);
    END;
    Note: in the above policy change the OBJECT_SCHEMA name to be the name of the user who owns the table you created in Step 1
    Step 6: Go into Discoverer Admin and import the table as a new folder.
    Be sure to uncheck the "Date hierarchies" box and set "Default aggregate on data points" to detail. Grant access to any user.
    Step 7: Using Desktop or Plus, log in as that user then try to query the folder with the date not included, there should be no problem.
    Step 8: Now try to query with the date included
    On my 10.2 database I get ORA-24334: no descriptor for this position. This happens when logged into Discoverer as the table owner, EUL owner or any other user. However, when logged into Discoverer as SYS which is exempt from all VPD policies, there is no error when the date is included.
    We tried this in Discoverer Desktop, Plus and Viewer with the same results in all three. We can successfully query the table from SQL*Plus, SQL Developer and TOAD.
    There also seems to be no issue at all with the 10.1 database so there seems to be an issue between Discoverer and the 10.2 database.
    What do you think?
    P.S. to cancel the policy use this script when logged in as SYS:
    EXEC DBMS_RLS.drop_policy(
    OBJECT_SCHEMA => 'DRAKE',
    OBJECT_NAME => 'TST_DATE',
    POLICY_NAME => 'SecByTST');
    This same information is available on my blog in a more readable format here:
    http://learndiscoverer.blogspot.com/2006/12/vpd-date-issue-between-101-and-102.html

    Hi Rod
    Well don't you just love Oracle. Obviously, whatever tests were done for certifying Discoverer against the 10.2 database did not include checking VPD policies. This merits a blog entry from me.
    Your workaround for V_PREDICATE VARCHAR2(2000) := 'BIRTH_DATE=TO_DATE(''01-JAN-0001'')'; works. However, I had to write a new function to do this because my real function was trapping about a dozen items at the same time, some dates, some numbers and some varchars - exactly the way that the Oracle example code shows it in the 10.2 database manual.
    So what I did was to create a new function that only handles dates and added a dedicated policy that works with only that function. Unfortuately, because I have many dates to manage, I was unabe to hard code the BIRTH_DATE so here is what I did:
    V_PREDICATE VARCHAR2(2000) := 'SYSDATE = TO_DATE(''01-JAN-0001'')';
    This works perfectly and Discoverer stopped complaining. It just has two policies on the same table for different data items. Isn't VPD cool? I'm hooked.
    I really appreciate your time and effort on this. Now, let's see what Oracle support make of the issue because I raised a service request last night. No reply yet I'm afraid.
    Best wishes
    Michael

  • Adobe Flash IDE: Migration/Compatibility issues between Adobe Flash Professional CS3 and CS5

    Hi,
    Adobe Flash IDE: Adobe Flash CS3 Professional and Adobe Flash Professional CS5
    I am facing some  migration/compatibility issues between Adobe Flash CS3 Professional and Adobe  Flash Professional CS5:
    I am working on a project that has  been completely developed in CS3 earlier. When I am using CS5 (Flash Player 9 /  Flash Player 10) to compile the FLA files, it is creating some new issues like  some customized radio buttons are getting disappeared while viewing the SWF on a  web page etc.
    So, I would like to  know:
    1) Is there any  migration/compatibility issue between Adobe Flash CS3 Professional and Adobe  Flash Professional CS5?
    2) If yes: Is there any patch  available from Adobe for it?
    3) If no: What could be the causes  and the best possible solutions for it?
    Any help and support would be highly  appreciated. Many thanks in advance!
    Thanks & Regards
    Amit

    Apparently some people have issues, but I don't think it is across the board.  Here's a link to another recent posting that may or may not prove helpful to you...
    http://forums.adobe.com/thread/776615?tstart=60

  • Itunes photo syncing issues between laptop/ipad

    I'm syncing photos on my laptop to my new ipad2 via itunes and randomly in each folder around 10% of the photos always come out corrupted with horizontal lines or even half the picture missing.  Have tried reinstalling itunes etc but still get random corruption issues.  Have managed to successfully import the photos if I save them to my camera and import via the camera connection kit but don't want to do that for the thousands of photos I have on my laptop.  Any ideas?

    I have now managed to find the cause of the problem.  All down to a conflict issue between itunes and Zonealarm.  The solution is to go into program access in Zonealarm and ensure that the iTunes Photo Processor program is set to NO ENFORCEMENT for trust level.   An alternative is to temporarily stop Zonealarm, sync and then turn on Zonealarm back on.  If you don't do this, a number of the photos (and it appears to be at random) become corrupted.  Hope this helps anyone else running Zonealarm.

  • White space issues between content and footer.

    I am having white space/page length issue between the end of my content and the footer.
    I have read the forums and tried changing the page length minium height to 800 and then I
    unchecked the sticky footer in page properties on both the master page and the content page itself.
    Here's a link to one of my pages.  http://www.ueonline.com/rohs-info.html
    This page has very little content and you can see the white space.
    Any help is appreciated.

    This may be a little dated for a reply, and I'm not 100% sure your issue is the same as mine, but I discovered that unchecking the sticky footer option in site properties solved the problem. I should note that the website I was building for a client was über simple, and while disabling that function solved the headache in my own project, it may incur unwanted results in others, depending on the complexity.
    DTA

  • Formatting issue between browsers

    Good Morning,
    I generally do not have issues between browsers, however, am having a major formatting issue this morning that I can't seem to figure out.
    Because I do not generally have this issue, I have no idea how to fix it.
    http://online.saintleo.edu/Request-Info-Splash.html
    Looks perfect in Firefox, but in Chrome and IE, spacing and formatting is way off.
    What is the easiest way to correct this?
    Thank you in advance for your time and assistance.

    KINNEY201 wrote:
    Obviously….but if I knew what it was specifically I wouldn’t be asking.
    #2 of course there’s a reason, and one that isn’t relevant to my question.
    Let this pass and let someone else answer.
    For someone asking for 'free' help, you're pretty dam* rude....

  • Link between queries and roles

    Hello,
    Could someone tell me if there is a way to have an overview on the link between roles and queries?
    For example a table which give us a role and the liste of queries which are linked to this role.
    Thanks in advance.
    Hicham

    Hi,
    I also had same query :
    mapping between the query/report and the role with technical names - BI Sec
    Its a bit tricky.
    Actually there are no direct linkage between queries and roles. However, you can look up S_RS_COMP in the roles that will help you identify which all queries the role gives access to.
    Regards,
    Zaheer
    Edited by: Zaheer on Aug 28, 2008 4:19 PM

Maybe you are looking for