SQL tooks more time at first and even more thru APP
Hello,
SQL
SELECT *
FROM (SELECT CASE
WHEN 'N' = 'Y'
THEN
ABCDEF_security.mask_data (
SUBSTR (LPAD (ly.MEMBER_name_1050, 6, ' '), 6))
ELSE
DECODE (
0,
0, (MEMBER_NAME_1050),
DECODE (
SEARCH_MEMBERS_PKG.de_identify_MEMBER (
ly.MEMBER_ID,
'400',
'N',
'Y'),
'Y', ABCDEF_security.mask_data (
SUBSTR (
LPAD (ly.MEMBER_name_1050, 6, ' '),
6))))
END
"Name",
CASE
WHEN 'N' = 'Y'
THEN
ABCDEF_security.mask_data (ly.MEMBER_ID)
ELSE
DECODE (
0,
0, (LY.MEMBER_ID),
DECODE (
SEARCH_MEMBERS_PKG.de_identify_MEMBER (
ly.MEMBER_ID,
'400',
'N',
'Y'),
'Y', ABCDEF_security.mask_data (
ly.MEMBER_ID)))
END
"Member ID",
CASE
WHEN 'N' = 'Y'
THEN
TO_DATE ('01/01/9999', 'MM/DD/YYYY')
ELSE
DECODE (
0,
0, (LY.DATE_OF_BIRTH_MEMBER),
DECODE (
SEARCH_MEMBERS_PKG.de_identify_MEMBER (
LY.MEMBER_ID,
'400',
'N',
'Y'),
'Y', ABCDEF_security.mask_data (
ly.DATE_OF_BIRTH_MEMBER)))
END
"Date of Birth",
CASE
WHEN 'N' = 'Y'
THEN
ABCDEF_security.mask_data (
(SUBSTR (
LPAD (
(LY.MEMBER_SEX_1210) || ' - ' || ly.age,
7,
'0'),
6)))
ELSE
(LY.MEMBER_SEX_1210) || ' - ' || age
END
"Gender",
(SELECT ff.sum_ind
FROM IND_LIST ff
WHERE ff.MEMBER_ID = ly.MEMBER_ID)
AS "Flags",
search_MEMBERs_pkg.fn_check_MEMBER_status (
ly.MEMBER_ID,
'400',
NULL)
AS "ACCESS",
ly.MEMBER_ID AS "RealMemberID"
FROM (SELECT DISTINCT aa.*
FROM ( (SELECT *
FROM MEMBER_last1year dr
WHERE dr.MEMBER_ID IN
(SELECT /*+ parallel(rp1, 8) */
rp1.MEMBER_ID
FROM search_auditor rp1
WHERE rp1.Member_auditor_ID =
'400'))
UNION ALL
SELECT dr.*
FROM MEMBER_last1year dr,
(SELECT MEMBER_ID
FROM CONSUMER
WHERE Member_auditor_ID = '400'
AND ( (ERD_IND = 'Y'
AND (SYSDATE
- NVL (ERD_IND_DATE,
SYSDATE)) <= 3)
OR (CSD_IND = 'Y'
AND (SYSDATE
- CSD_DATE <=
(365 * 3))))) cc
WHERE CC.MEMBER_ID = DR.MEMBER_ID) aa
WHERE ROWNUM < 51) LY
WHERE 1 = 1 )
/This SQL is running 2 seconds from SQLPlus, but running through the application (ASP.NET), it's taking more than *2 minutes*
What could be the reason, where do I find that out, and how do I tune. Actually when running at first time it is taking little bit longer about 30 seconds.
Explain plan
| Id | Operation | Name | Rows | Bytes |TempSpc| Cost | Pstart| Pstop | TQ |IN-OUT| PQ Distrib |
| 0 | SELECT STATEMENT | | 50 | 489K| | 869 | | | | | |
| 1 | TABLE ACCESS BY INDEX ROWID | IND_LIST | 1 | 27 | | 1 | | | | | |
|* 2 | INDEX RANGE SCAN | IX1_IND_LIST | 1 | | | 1 | | | | | |
| 3 | VIEW | | 50 | 489K| | 869 | | | | | |
|* 4 | COUNT STOPKEY | | | | | | | | | | |
| 5 | VIEW | | 50 | 2350 | | 869 | | | | | |
|* 6 | SORT UNIQUE STOPKEY | | 50 | 7600 | 12M| 869 | | | | | |
|* 7 | COUNT STOPKEY | | | | | | | | | | |
| 8 | PX COORDINATOR | | | | | | | | | | |
| 9 | PX SEND QC (RANDOM) | :TQ10002 | 31659 | 4699K| | 433 | | | Q1,02 | P->S | QC (RAND) |
| 10 | BUFFER SORT | | 50 | 489K| | | | | Q1,02 | PCWP | |
|* 11 | COUNT STOPKEY | | | | | | | | Q1,02 | PCWC | |
| 12 | VIEW | | 31659 | 4699K| | 433 | | | Q1,02 | PCWP | |
| 13 | UNION-ALL | | | | | | | | Q1,02 | PCWP | |
| 14 | TABLE ACCESS BY INDEX ROWID | MEMBER_LAST1YEAR | 1 | 108 | | 1 | | | Q1,02 | PCWP | |
| 15 | NESTED LOOPS | | 31650 | 3678K| | 429 | | | Q1,02 | PCWP | |
| 16 | SORT UNIQUE | | 47543 | 510K| | 11 | | | Q1,02 | PCWP | |
| 17 | PX RECEIVE | | 47543 | 510K| | 11 | | | Q1,02 | PCWP | |
| 18 | PX SEND HASH | :TQ10001 | 47543 | 510K| | 11 | | | Q1,01 | P->P | HASH |
| 19 | PX BLOCK ITERATOR | | 47543 | 510K| | 11 | KEY | KEY | Q1,01 | PCWC | |
| 20 | TABLE ACCESS FULL | SEARCH_AUDITOR | 47543 | 510K| | 11 | 36 | 36 | Q1,01 | PCWP | |
|* 21 | INDEX RANGE SCAN | IX1_MEMBER_LAST1YEAR | 1 | | | 1 | | | Q1,02 | PCWP | |
| 22 | BUFFER SORT | | | | | | | | Q1,02 | PCWC | |
| 23 | PX RECEIVE | | 1 | 108 | | 1 | | | Q1,02 | PCWP | |
| 24 | PX SEND ROUND-ROBIN | :TQ10000 | 1 | 108 | | 1 | | | | S->P | RND-ROBIN |
| 25 | TABLE ACCESS BY INDEX ROWID | MEMBER_LAST1YEAR | 1 | 108 | | 1 | | | | | |
| 26 | NESTED LOOPS | | 9 | 1170 | | 4 | | | | | |
|* 27 | TABLE ACCESS BY INDEX ROWID | CONSUMER | 9 | 198 | | 2 | | | | | |
| 28 | BITMAP CONVERSION TO ROWIDS| | | | | | | | | | |
|* 29 | BITMAP INDEX SINGLE VALUE | IDX1_CONSUMER | | | | | | | | | |
|* 30 | INDEX RANGE SCAN | IX1_MEMBER_LAST1YEAR | 1 | | | 1 | | | | | |
------------------------------------------------------------------------------------------------------------------------------------------------------------------SEARCH_AUDITOR, --partitioned, it's looking into the right partition.
Any help would be greatly appreciated.
Is that could be a reason to read from the file (For the first time) and subsequently from Memory (I am not sure about this)
Then that should be run thru the APP faster, just thinking ...
Thanks,
Once again from the top.
This is undoubtedly not a database issue.
I doubt you can fix it in the database.
You can, however, spend a lot of hours asking questions and poking around if you are a consultant paid by the hour.
But as long as you are looking for something to do here are some that won't fix the problem but may be worth a few minutes of your time.
WHERE 1 = 1Are you kidding? Drop this nonsense. The Oracle optimizer is not brain dead. If it were my database I would also drop the parallel hint like a bad habit.
/*+ parallel(rp1, 8) */Again the Oracle optimizer is not brain dead. Ask for parallel threads that don't exist and the database will just queue your SQL and let it sit there until sufficient resources become available.
Similar Messages
-
when I move my mouse Itunes stops playing music. Sometimes this happens immediatly and sometime it take 10 to 15 sec. I tried playing Itunes and then tabing another program but same result. If I click on play and do not move mouse Itunes works as usual.. This was happening before I installed latest version. I have installed latest version three times. First and install, then as a repair, and third time I unistalled Itunes and reinstalled i.
when I move my mouse Itunes stops playing music. Sometimes this happens immediatly and sometime it take 10 to 15 sec.
At various stages over the years, mouse-related iTunes trouble has been associated with driver conflicts. So it might be worth following up on that possibility.
Head to the drivers and downloads page for your model of PC, and check to make sure you're not behind on any chipset and input-device-related driver updates. (And while there, just in case, also check to make sure your BIOS, sound-card/integrated audio, and video-card/display-adaptors are up to date.)
If you're behind on anything, and you update, does that help with the mouse-related iTunes issues? -
Every time I try and download a FREE app it tells me put in my payment method and when I do says can't be accepted
If you still have problem, contact iTune Support
https://ssl.apple.com/emea/support/itunes/contact.html -
when i go to update my app i have to put my apple id password but instead of having my email address it has someone else's. On my computer it has my email on my itunes it has my email, and even on the app store it has my email
Did you purchase the iPhone second hand?
Has anybody else signed into their Apple ID on your iPhone? -
Every time i try and get on the apps it comes up with server connection error
every time i try and get on to the apps it keeps comeing up with server connection error -1
Hi,
Please refer the link below to troubleshoot the issue
http://h30434.www3.hp.com/t5/Printer-Networking-and-Wireless/Web-Services-problem-Server-connection-...
Although I am an HP employee, I am speaking for myself and not for HP.
--Say "Thanks" by clicking the Kudos Star in the post that helped you.
--Please mark the post that solves your problem as "Accepted Solution" -
How can I put my itunes library on my Airport Time Capsule 3TB and still play thru Apple TV?
I am trying to free up space on my 1TB iMac and would like to put iTunes/burned movies/music to Airport Time Capsule 3tb. At the same time I would like tobe able to play said media through my Apple TV.
Quick answer if you use iTunes' default preferences settings: Copy the entire iTunes folder (and in doing so all its subfolders and files) intact to the other drive. Open iTunes and immediately hold down the option (alt) key (shift on Windows) so you get a prompt to select a library, then guide it to the 'iTunes Library.itl' file in the moved iTunes folder.
-
The application by the way is a game called Max Payne 3 which I downloaded from Steam by the way.
Press command + option + esc keys together at the same time.
Wait.
When Force Quit window appears, select the application if not already.
Press Force Quit button at the bottom of the window.
Wait.
Application will quit.
If this does not help, press the power button for 7 or more seconds.
Computer will shut down.
Restart.
http://support.apple.com/kb/HT3411 -
Apple Apps like Weather, the App Store and even the Facebook App don't work on WIFI
Since a few days all my apple apps (Itunes, AppStore, Weather) don't work via Wifi. The strange thing is that all other apps work without problems (just Facebook and Youtube don't view profile pictures). Via 3G all apps work without any problems. I just set my router to default settings but the problem keeps existing. Would be great if someone could help me!
I read about the following:
Workarounds:
Make sure that Bluetooth is turned off.
Turn the Stamina Mode off. It should be off by default, but you can check inSettings > Power management > STAMINA mode.
Possible solutions:
Restart the router and the phone.
Double check that you have the right details and password.
Ensure that you have the latest firmware. For your Xperia Z this should come as an OTA update, but for your router you’ll need to check the manufacturer’s website or with your ISP.
Try changing the channel on your router and make sure that DHCP is on.
Turn MAC filter off on your router and/or add your phone’s MAC address.
Try Sony’s PC Companion. Install on your PC and go to Support Zone > Start > Phone Software Update > Start. If you already have the latest version chooseRepair phone and follow the instructions. -
How can I change my App Store to another country?
Click on your account name in the top right corner of the iTunes store in the iTunes application on your computer, enter your password and click the "view account" button. Navigate to the Apple ID summary where you have the option to "change country or region".
In order to change your location, you will need a credit card registered to an address in the location you are trying to change to.
You cannot change your location if you have credit on your account, if you are unable to spend your credit and leave a balance of zero, contact Apple, which you can do through iTunes Store Support.
Note however, I would not recommend keep changing stores, in some instances you may find yourself locked out from changing back for 90 days. -
Time-remapping nesting and zooms
So I've got a clip that I want to slow down and zoom Its a 1080p clip on a 720 timeline.
If i was just zooming I'd setup the keyframes and zoom out. But you cant zoom and time-remap, and if you do the time remapping first and then nest, the zoom wont work, and if you do it the other way round you have to try to imagine what your zoom will look like with the time-remapping applied.
Is there another way?What version?
-
I just got the iPhone 5 and took it on a trip and took a bunch of photos on it. I just came home and hooked it up to my Mac for the first time and hit restore. All of my trip pictures disappeared. Is there any way I can retrieve them?
Did you by chance have photo stream turned on? If so then they might be there. When you restored your phone it deleted everything and they will be unretreivable from your computer.
-
ADF application taking more time for first time and less from second time
Hi Experts,
We are using ADF 11.1.1.2.
Our application contains 5 jsp pages, 10 - 12 taskflows, and 50 jsff pages.
For the first time in the day if we use the application it is taking more than 60 sec on some actions.
And from the next time onwords it is taking 5 to 6 sec.
Same thing is happening daily.
Can any one tell me why this application is taking more time for first time and less time from second time.
Regards
GayazHi,
If you don't restart you WLS every day, then you should read about Tuning Application Module Pools and Connection Pools
http://docs.oracle.com/cd/E15523_01/web.1111/b31974/bcampool.htm#sm0301
And pay attention to the parameter: Maximum Available Size, Minimum Available Size
http://docs.oracle.com/cd/E15523_01/web.1111/b31974/bcampool.htm#sm0314
And adjust them to suit your needs. -
Last time I bought “Oxford Advanced Learner’s Dictionary”.
But since I update my phones to iOS6, I noticed the “OALD” was no more in my phone nor my families’ iPhones or iPad and even not in my purchased list it just show me S$ 38.98.
Can you advise me?Simple process. If an iPhone go to the Apple Store and not Verizon
the phone from Verizon will be a refurbished device and not new unless under the 14 day worry free guarantee
good luck -
How to get the first and the last record of every month within a time range in sql
I am trying to get the first record and the last record of each and every month in a given date range using sql. I have a sample code
where i have just selected everything within the date range now i have to extract the first and the last records of each and every month.
SELECT PurOrderNum,
OrderDate
FROM Purchasing.PurOrder
WHERE OrderDate >= '2013-02-28'
AND OrderDate <= '2014-12-29'SELECT PurOrderNum,
OrderDate
FROM
SELECT PurOrderNum,
OrderDate,
MAX(OrderDate) OVER (PARTITION BY DATEDIFF(mm,0,OrderDate)) AS MaxDate,
MIN(OrderDate) OVER (PARTITION BY DATEDIFF(mm,0,OrderDate)) AS MinDate
FROM Purchasing.PurOrder
WHERE OrderDate >= '2013-02-28'
AND OrderDate <= '2014-12-29'
)t
WHERE OrderDate = MaxDate
OR OrderDate = MinDate
Please Mark This As Answer if it solved your issue
Please Vote This As Helpful if it helps to solve your issue
Visakh
My MSDN Page
My Personal Blog
My Facebook Page -
the 2 movies on itunes i purchased, and put on itunes,for travel. i also added music that i also had to my itunes on my computer. heck, i was charged more for the movies, than i paid for them on my original purchase of them when i put them on itunes. the music on itunes was also music that i purchased the cd's, myself, and loaded onto my computer so that i would be able to carry it with me when i went on a trip..but when i got my bill, i was being charged for purchasing them again...is that how itunes works? if it is i will not be adding any more of my movies, or music on it at all. iphone or computer? by the time i got the bill it had added allmost 40+ dollars to my bill. and no i was not over my space i had for my phone, and definitely had room on my computer. so please. if thats how it works tell me and i will not add any more to my itune acct. i was quite stunned to see what additional charges i was paying again, and even worse more than i'd paid for it all the first time when i purchased....i have sent an email upon figuring out what had made my bill so high, just as i am now. as of today i have not gotten any response from customer support. if this is the case i will not only not use itunes on any of my devices but i will see that upon renewal of my contract. i will NOT purchase any device that you have to use iturnes on it....i have spoke to several people and they had the same thing happen to them. so do we have to pay JUST to add our own movies music etc to itunes. cause if thats the case i will go back to other phones and won't have to deal with itunes.i didn't PUCHASE any of it from itunes, and if i had i would have done it only with an itunes card just to avoid and have control of my bill, as i thought that i would..so please let me know if i have to pay again for my OWN items,i put on itunes. i had plenty of space on my computer, the cloud, dropbox etc. that wouldn't even make any sense for anyone to do it....please respond, it has taken a while to send again due to several very personal tragedies i have been a bit behind in getting this cone again but i would love to get or have someone explain WHY i am paying for music and movies that i had and thought it was a good idea to put on my computer for travellimg purposes. i hope and would appreciate an acknowledgement of this letter, and also a response...because if that's the case i won't be using itunes any more for adding movies or music to itunes, and on top of that paying for it all a second time, and it also being more than i had originally paid for them when and where i purchased them..i have been please with all my apple products till that happened, now not so sure....i have to keep up with all of my expenses for medical reasons..i hope that i get a response this time. i also have 2 other email addresses, [email protected], and [email protected],i used them to try to use them to set up my acct., but for whatever reason said they were invalid and i have had them for several years, no problem with any one else......
sheila vest
[email protected]Paragraphs were invented for a reason.
Flinging a giant wall of text up is not conducive to receiving help.
Posting email addresses is not smart.
User to user forum-Apple is nit here.
Maybe you are looking for
-
When I open my browser, it takes 3-5 minutes to fully open. When I get to a website, randomly the tab will say 'Connecting' and slow down and take 10-15 minutes to function or freeze completely. This almost always happens on sites that require Flash
-
My MacBook Pro 15 Inch is a early 2008 model. It is a 2.4 Core 2 Duo. I'm confused if it can take a max of 3 or 4 GB RAM. Right now it has 2 GB. First question: Can it take 3 or 4? Second question: Will I notice an increase in speed? BTW - I check
-
CcBPM - process stopped and SXMB_MONI_BPE without entries
Hello, We have a strange behaviour of ccBPM on SAP PI 7.01. Sometimes ccBPMs are not working properly. So e.g. process is not started or in SXMB_MONI_BPE showing that a wrong lane after a switch is started. Usually we could resolve that by reimportin
-
G62-234DX replaced hard drive with new Samsung 250 GB. Same size as installed.
G62-234DX Hard drive dead. I replaced hard drive with new Samsung 250 GB. SATA II hard drive and used the recovery Windows 7 Home edition DVD. Error message appeared after windows loads files and starts windows from the recovery DVD. An error dia
-
Rumor confirmed: CS4 will remain 32-bit for Mac, but will be 64-bit in Windows
Photoshop, Lightroom, and Adobe's 64-bit roadmap http://blogs.adobe.com/jnack/ CS4 will remain 32-bit for Mac, but will be 64-bit in Windows.