Issue with sql performance

Hi, I am experiencing an issue with a couple of sql statements.   The rest of the db seems to be performing optimally.
A little history:  Stats typically were never touched on this db and they were old (I mean very very old).  However, the database performance was optimal.  Recently we ran into an issue (turned out to be hardware), but in the troubleshooting, we deleted the old statistics and refreshed the stats across the board. 
Prior to this incident, these queries would finish in mere minutes.
Performance for a few queries is sub optimal now.
When I execute this query it is performing ok returning a values in just over a minute.
select MAX(fr.fee_rqst_sid)
      from fee_rqst fr
      where fr.prcd_dt <=  to_date('15/10/2013', 'DD/MM/RRRR');
Elapsed: 00:01:10.17
Plan hash value: 3146244357
| Id  | Operation          | Name     | Rows  | Bytes | Cost (%CPU)| Time     |
|   0 | SELECT STATEMENT   |          |     1 |    23 |   404K  (2)| 01:20:49 |
|   1 |  SORT AGGREGATE    |          |     1 |    23 |            |          |
|*  2 |   TABLE ACCESS FULL| FEE_RQST |   148M|  3262M|   404K  (2)| 01:20:49 |
When it is executed as part of the slightly larger query it belongs to performance drops to over 40 minutes.
    select MAX(ch.clm_hdr_sid)
    from clm_hdr ch
    where ch.fee_rqst_sid <= (
      select MAX(fr.fee_rqst_sid)
      from fee_rqst fr
      where fr.prcd_dt <=  to_date('15/10/2013', 'DD/MM/RRRR'));
PLAN_TABLE_OUTPUT
Plan hash value: 2801176651
| Id  | Operation                    | Name       | Rows  | Bytes | Cost (%CPU)| Time     |
|   0 | SELECT STATEMENT             |            |     1 |    12 |   718K  (1)| 02:23:41 |
|   1 |  SORT AGGREGATE              |            |     1 |    12 |            |          |
|   2 |   TABLE ACCESS BY INDEX ROWID| CLM_HDR    |  9410K|   107M|   718K  (1)| 02:23:41 |
|*  3 |    INDEX RANGE SCAN          | IDX$_00002 |  1879K|       |  8533   (1)| 00:01:43 |
|   4 |     SORT AGGREGATE           |            |     1 |    23 |            |          |
|*  5 |      TABLE ACCESS FULL       | FEE_RQST   |   148M|  3262M|   404K  (2)| 01:20:49 |
I've create/dropped an index on the date column figuring it might help but it did not as a full table scan still occurred.
The primary key indexes have up to date stats and are not corrupted  indexes.
Again this is production and the rest of the db is running optimally and this db is used heavily.
I did run a sqltune but no new results yielded.
GENERAL INFORMATION SECTION
Tuning Task Name   : sql_tuning_task1
Tuning Task Owner  : SYS
Workload Type      : Single SQL Statement
Scope              : COMPREHENSIVE
Time Limit(seconds): 60
Completion Status  : COMPLETED
Started at         : 04/21/2015 16:23:18
Completed at       : 04/21/2015 16:24:15
Schema Name: SYS
SQL ID     : g52fuy8db7qgb
SQL Text   : select MAX(ch.clm_hdr_sid)
                 from npf.clm_hdr ch
                 where ch.fee_rqst_sid <= (
                   select MAX(fr.fee_rqst_sid)
                   from npf.fee_rqst fr
                   where fr.prcd_dt <=  to_date('15/10/2013', 'DD/MM/RRRR'))
There are no recommendations to improve the statement.
Any advice on what else I can check?

Before asking this question, next time you would need to ask this forum to clean their crystal balls.
Your many many lines boil down to:
My car doesn't run, please fix my car, as there is insufficient INFORMATION to work on, and plenty of RIDDLES
1 Your database doesn't seem to have a four digit version
2 Your database doesn't seem to run on an OS
3 The statistics where 'refreshed across the board'. How that happened, this forum needs to guess.
4 Which indices are present on this table, this forum needs to guess
5 Which part of the table satisifies the where clause, this forum needs to guess.
So the obvious would be to answer all of these questions AND run the statement with event 10053 set, so the optimizer decisions are dumped to a trace file,
See https://asktom.oracle.com/pls/asktom/f?p=100:11:0%3A%3A%3A%3AP11_QUESTION_ID:63445044804318
And lastly, I find it more and more annoying, many people don't seem to a have a name, and post 100 percent anonymously.
Sybrand Bakker
Senior Oracle DBA

Similar Messages

  • Issues with WebForm performance

    Hi,
    We had migrated a new application from UAT to PROD and we encounter webform performance issues with the following actions..
    After login, the first form you open it is
    always slow. After this you can switch from one form to another without a
    delay.
    Then once you change any data – the next time
    you access a form it gets delayed.
    The point to be noted is, it doesnt have any performance issues in the UAT environment and the configuration settings,essbase cache settings are all the same. We did try to move the EPM system to a new server to see if this is a hardware issue but no luck, the performance issues still exist. The consumption of the CPU/memory has been checked and it is proved that the form opening delay has nothing to do with lack of memory.
    The JVM head settings is set up at 4GB which is infact higher than that of the UAT environment(2GB).
    runs on Windows server2008,11.1.2.1.600 EPM serve, has planning,reporting,foundation on one server (32GB ram) and essbase on another server (32GB ram). Any help is appreciated.
    Please find attached the planning logs below and there is nothing mentioned in the hyperionplanning error logs.-----------------------------------------------------------------------------------------------------------------------------------------------------------------
    <Nov 5, 2013 8:05:43 PM CET> <Info> <Security> <BEA-090905> <Disabling CryptoJ JCE Provider self-integrity check for better startup performance. To enable this check, specify -Dweblogic.security.allowCryptoJDefaultJCEVerification=true>
    <Nov 5, 2013 8:05:43 PM CET> <Info> <Security> <BEA-090906> <Changing the default Random Number Generator in RSA CryptoJ from ECDRBG to FIPS186PRNG. To disable this change, specify -Dweblogic.security.allowCryptoJDefaultPRNG=true>
    <Nov 5, 2013 8:05:44 PM CET> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with Oracle JRockit(R) Version R28.0.2-11-135406-1.6.0_20-20100624-2119-windows-x86_64 from Oracle Corporation>
    <Nov 5, 2013 8:05:46 PM CET> <Info> <Management> <BEA-141107> <Version: WebLogic Server 10.3.4.0  Fri Dec 17 20:47:33 PST 2010 1384255 >
    <Nov 5, 2013 8:05:48 PM CET> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
    <Nov 5, 2013 8:05:48 PM CET> <Info> <WorkManager> <BEA-002900> <Initializing self-tuning thread pool>
    <Nov 5, 2013 8:05:48 PM CET> <Notice> <Log Management> <BEA-170019> <The server log file C:\Oracle\Middleware\user_projects\domains\EPMSystem\servers\Planning0\logs\Planning0.log is opened. All server side log events will be written to this file.>
    <Nov 5, 2013 8:06:22 PM CET> <Notice> <Security> <BEA-090082> <Security initializing using security realm myrealm.>
    <Nov 5, 2013 8:06:28 PM CET> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STANDBY>
    <Nov 5, 2013 8:06:28 PM CET> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
    Calling getConnection()
      return weblogic.management.jmx.mbeanserver.WLSMBeanServer@327b36fb
    Calling getDomainConfiguration()
    Calling getConnection()
      return weblogic.management.jmx.mbeanserver.WLSMBeanServer@327b36fb
    Calling getRuntimeService()
    Calling getConnection()
      return weblogic.management.jmx.mbeanserver.WLSMBeanServer@327b36fb
      return com.bea:Name=RuntimeService,Type=weblogic.management.mbeanservers.runtime.RuntimeServiceMBean
      return com.bea:Name=EPMSystem,Type=Domain
    Calling getConnection()
      return weblogic.management.jmx.mbeanserver.WLSMBeanServer@327b36fb
    Domain location is 'C:\Oracle\Middleware\user_projects\domains\EPMSystem'
    Calling getRuntimeService()
      return com.bea:Name=RuntimeService,Type=weblogic.management.mbeanservers.runtime.RuntimeServiceMBean
    Calling getConnection()
      return weblogic.management.jmx.mbeanserver.WLSMBeanServer@327b36fb
    Calling getConnection()
      return weblogic.management.jmx.mbeanserver.WLSMBeanServer@327b36fb
    Calling getConnection()
      return weblogic.management.jmx.mbeanserver.WLSMBeanServer@327b36fb
    Calling getConnection()
      return weblogic.management.jmx.mbeanserver.WLSMBeanServer@327b36fb
    Checking C:\Oracle\Middleware\user_projects\domains\EPMSystem\servers\Planning0\registry_update.xml file
    EPM_ORACLE_HOME: C:\Oracle\Middleware\EPMSystem11R1
    Template for PLANNING#11.1.2.0: C:\Oracle\Middleware\EPMSystem11R1\common\templates\applications\epm_planning_11.1.2.1.jar
    Dependencies for C:\Oracle\Middleware\EPMSystem11R1\common\templates\applications\epm_planning_11.1.2.1.jar: []
    BPMUI shared webapp not referenced from PLANNING#11.1.2.0
    Application name: PLANNING#11.1.2.0
    Application source: HyperionPlanning.ear
    Server name: Planning0
    Server port: 8300
    Server SSL port: 8343
    Application context: HyperionPlanning
    Registry product type: PLANNING_PRODUCT
    Registry physical web application type: PLANNING_WEBAPP
    weblogic.Name property is 'Planning0', seems to be WebLogic mode
    registry.isRegistryDatabaseCreated()true
    Registry was initialized sucessfully
    Executing pre custom update for PLANNING#11.1.2.0
    EPM_ORACLE_INSTANCE: C:\Oracle\Middleware\user_projects\epmsystem1
    Physical Web App found
    Web app already linked to some application server: false
    The registry was not modifyed because it already containse all sturctures
    Web app is already linked to the logical web app
    No needs to run custom updater for PLANNING#11.1.2.0
    loggingUpdatePLANNING.block file exist or the system is running in the Fusion mode, skipping logging.xml configuration
    Planning locale: en_US
    <Nov 5, 2013 8:06:39 PM CET> <Notice> <Log Management> <BEA-170027> <The Server has established connection with the Domain level Diagnostic Service successfully.>
    <Nov 5, 2013 8:06:39 PM CET> <Notice> <Cluster> <BEA-000197> <Listening for announcements from cluster using unicast cluster messaging>
    <Nov 5, 2013 8:06:39 PM CET> <Notice> <Cluster> <BEA-000133> <Waiting to synchronize with other running members of Planning.>
    <Nov 5, 2013 8:07:09 PM CET> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to ADMIN>
    <Nov 5, 2013 8:07:09 PM CET> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RESUMING>
    <Nov 5, 2013 8:07:09 PM CET> <Notice> <Cluster> <BEA-000162> <Starting "async" replication service with remote cluster address "null">
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090171> <Loading the identity certificate and private key stored under the alias DemoIdentity from the jks keystore file C:\Oracle\MIDDLE~1\WLSERV~1.3\server\lib\DemoIdentity.jks.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090169> <Loading trusted certificates from the jks keystore file C:\Oracle\MIDDLE~1\WLSERV~1.3\server\lib\DemoTrust.jks.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090169> <Loading trusted certificates from the jks keystore file C:\Oracle\Middleware\jrockit_160_20\jre\lib\security\cacerts.>
    <Nov 5, 2013 8:07:10 PM CET> <Alert> <Security> <BEA-090152> <Demo trusted CA certificate is being used in production mode: [
      Version: V3
      Subject: CN=CACERT, OU=FOR TESTING ONLY, O=MyOrganization, L=MyTown, ST=MyState, C=US
      Signature Algorithm: MD5withRSA, OID = 1.2.840.113549.1.1.4
      Key:  Sun RSA public key, 512 bits
      modulus: 9550192877869244258838480703390456015046425375252278279190673063544122510925482179963329236052146047356415957587628011282484772458983977898996276815440753
      public exponent: 65537
      Validity: [From: Thu Mar 21 21:12:27 CET 2002,
                   To: Tue Mar 22 21:12:27 CET 2022]
      Issuer: CN=CACERT, OU=FOR TESTING ONLY, O=MyOrganization, L=MyTown, ST=MyState, C=US
      SerialNumber: [    33f10648 fcde0deb 4199921f d64537f4]
    Certificate Extensions: 1
    [1]: ObjectId: 2.5.29.15 Criticality=true
    KeyUsage [
      Key_CertSign
      Algorithm: [MD5withRSA]
      Signature:
    0000: 9D 26 4C 29 C8 91 C3 A7   06 C3 24 6F AE B4 F8 82  .&L)......$o....
    0010: 80 4D AA CB 7C 79 46 84   81 C4 66 95 F4 1E D8 C4  .M...yF...f.....
    0020: E9 B7 D9 7C E2 23 33 A4   B7 21 E0 AA 54 2B 4A FF  .....#3..!..T+J.
    0030: CB 21 20 88 81 21 DB AC   90 54 D8 7D 79 63 23 3C  .! ..!...T..yc#<
    ] The system is vulnerable to security attacks, since it trusts certificates signed by the demo trusted CA.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090898> <Ignoring the trusted CA certificate "CN=thawte Primary Root CA - G3,OU=(c) 2008 thawte\, Inc. - For authorized use only,OU=Certification Services Division,O=thawte\, Inc.,C=US". The loading of the trusted certificate list raised a certificate parsing exception PKIX: Unsupported OID in the AlgorithmIdentifier object: 1.2.840.113549.1.1.11.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090898> <Ignoring the trusted CA certificate "CN=T-TeleSec GlobalRoot Class 3,OU=T-Systems Trust Center,O=T-Systems Enterprise Services GmbH,C=DE". The loading of the trusted certificate list raised a certificate parsing exception PKIX: Unsupported OID in the AlgorithmIdentifier object: 1.2.840.113549.1.1.11.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090898> <Ignoring the trusted CA certificate "CN=T-TeleSec GlobalRoot Class 2,OU=T-Systems Trust Center,O=T-Systems Enterprise Services GmbH,C=DE". The loading of the trusted certificate list raised a certificate parsing exception PKIX: Unsupported OID in the AlgorithmIdentifier object: 1.2.840.113549.1.1.11.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090898> <Ignoring the trusted CA certificate "CN=GlobalSign,O=GlobalSign,OU=GlobalSign Root CA - R3". The loading of the trusted certificate list raised a certificate parsing exception PKIX: Unsupported OID in the AlgorithmIdentifier object: 1.2.840.113549.1.1.11.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090898> <Ignoring the trusted CA certificate "OU=Security Communication RootCA2,O=SECOM Trust Systems CO.\,LTD.,C=JP". The loading of the trusted certificate list raised a certificate parsing exception PKIX: Unsupported OID in the AlgorithmIdentifier object: 1.2.840.113549.1.1.11.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090898> <Ignoring the trusted CA certificate "CN=VeriSign Universal Root Certification Authority,OU=(c) 2008 VeriSign\, Inc. - For authorized use only,OU=VeriSign Trust Network,O=VeriSign\, Inc.,C=US". The loading of the trusted certificate list raised a certificate parsing exception PKIX: Unsupported OID in the AlgorithmIdentifier object: 1.2.840.113549.1.1.11.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090898> <Ignoring the trusted CA certificate "CN=KEYNECTIS ROOT CA,OU=ROOT,O=KEYNECTIS,C=FR". The loading of the trusted certificate list raised a certificate parsing exception PKIX: Unsupported OID in the AlgorithmIdentifier object: 1.2.840.113549.1.1.11.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Security> <BEA-090898> <Ignoring the trusted CA certificate "CN=GeoTrust Primary Certification Authority - G3,OU=(c) 2008 GeoTrust Inc. - For authorized use only,O=GeoTrust Inc.,C=US". The loading of the trusted certificate list raised a certificate parsing exception PKIX: Unsupported OID in the AlgorithmIdentifier object: 1.2.840.113549.1.1.11.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "DefaultSecure[3]" is now listening on 127.0.0.1:8343 for protocols iiops, t3s, CLUSTER-BROADCAST-SECURE, ldaps, https.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "DefaultSecure[1]" is now listening on fe80:0:0:0:0:5efe:a53:4816:8343 for protocols iiops, t3s, CLUSTER-BROADCAST-SECURE, ldaps, https.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "DefaultSecure[4]" is now listening on 0:0:0:0:0:0:0:1:8343 for protocols iiops, t3s, CLUSTER-BROADCAST-SECURE, ldaps, https.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "Default" is now listening on 10.83.72.22:8300 for protocols iiop, t3, CLUSTER-BROADCAST, ldap, snmp, http.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "Default[3]" is now listening on 127.0.0.1:8300 for protocols iiop, t3, CLUSTER-BROADCAST, ldap, snmp, http.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "Default[4]" is now listening on 0:0:0:0:0:0:0:1:8300 for protocols iiop, t3, CLUSTER-BROADCAST, ldap, snmp, http.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "Default[2]" is now listening on fe80:0:0:0:0:ffff:ffff:fffe:8300 for protocols iiop, t3, CLUSTER-BROADCAST, ldap, snmp, http.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "Default[1]" is now listening on fe80:0:0:0:0:5efe:a53:4816:8300 for protocols iiop, t3, CLUSTER-BROADCAST, ldap, snmp, http.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "DefaultSecure[2]" is now listening on fe80:0:0:0:0:ffff:ffff:fffe:8343 for protocols iiops, t3s, CLUSTER-BROADCAST-SECURE, ldaps, https.>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <Server> <BEA-002613> <Channel "DefaultSecure" is now listening on 10.83.72.22:8343 for protocols iiops, t3s, CLUSTER-BROADCAST-SECURE, ldaps, https.>
    <Nov 5, 2013 8:07:10 PM CET> <Warning> <Server> <BEA-002611> <Hostname "WIPLPRD01.svc.unicc.org", maps to multiple IP addresses: 10.83.72.22, 0:0:0:0:0:0:0:1>
    <Nov 5, 2013 8:07:10 PM CET> <Notice> <WebLogicServer> <BEA-000330> <Started WebLogic Managed Server "Planning0" for domain "EPMSystem" running in Production Mode>
    <Nov 5, 2013 8:07:12 PM CET> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RUNNING>
    <Nov 5, 2013 8:07:12 PM CET> <Notice> <WebLogicServer> <BEA-000360> <Server started in RUNNING mode>
    using java.library.path: C:\Oracle\Middleware\EPMSystem11R1/products/Planning/lib64;C:\Oracle\Middleware\EPMSystem11R1/bin;C:\Oracle\Middleware\EPMSystem11R1/common/EssbaseRTC-64/11.1.2.0/bin;C:\Oracle\MIDDLE~1\patch_wls1034\profiles\default\native;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\native\win\x64;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\bin;C:\Oracle\MIDDLE~1\modules\ORGAPA~1.1\bin;C:\Oracle\MIDDLE~1\JROCKI~1\jre\bin;C:\Oracle\MIDDLE~1\JROCKI~1\bin;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\native\win\x64\oci920_8
    EPM_ORACLE_HOME (C:\Oracle\Middleware\EPMSystem11R1) is set from JVM property "EPM_ORACLE_HOME".
    using Java property for Hyperion Home C:\Oracle\Middleware\EPMSystem11R1
    EPM_ORACLE_INSTANCE (C:\Oracle\Middleware\user_projects\epmsystem1) is set from JVM property[EPM_ORACLE_INSTANCE].
    Reaquired task list lease: Tue Nov 05 20:11:49 CET 2013: 1383678709156
    Seeking ESAPI.properties
      Found in 'org.owasp.esapi.resources' directory: C:\Oracle\Middleware\EPMSystem11R1\products\Planning\config\esapi\ESAPI.properties
    Loaded 'ESAPI.properties' properties file
    Seeking validation.properties
      Found in 'org.owasp.esapi.resources' directory: C:\Oracle\Middleware\EPMSystem11R1\products\Planning\config\esapi\validation.properties
    Loaded 'validation.properties' properties file
    Seeking antisamy-esapi.xml
      Found in 'org.owasp.esapi.resources' directory: C:\Oracle\Middleware\EPMSystem11R1\products\Planning\config\esapi\antisamy-esapi.xml
    EnterData_Inner Processing Time:424
    2013-11-05 20:14:47,454 INFO Thread-51 calcmgr.launch - Date/Time Started: 2013/11/05:20:14:47.452 CET Server/Application/Database: localhost/1415_WP/AWP Business Rule Name: WPA_Count By Planning user: wipoadmin Values entered for run-time prompts: [Variable] Wrk_Scenario:"Work_Plan_2014"[Variable] Funds:"Regular"[Variable] Units:"0001"
    - Date/Time Started: 2013/11/05:20:14:47.452 CET Server/Application/Database: localhost/1415_WP/AWP Business Rule Name: WPA_Count By Planning user: wipoadmin Values entered for run-time prompts: [Variable] Wrk_Scenario:"Work_Plan_2014"[Variable] Funds:"Regular"[Variable] Units:"0001"
    2013-11-05 20:14:54,066 INFO Thread-51 calcmgr.launch - Date/Time Ended: 2013/11/05:20:14:54.066 CET Server/Application/Database: localhost/1415_WP/AWP Business Rule Name: WPA_Count By Planning user: wipoadmin.
    - Date/Time Ended: 2013/11/05:20:14:54.066 CET Server/Application/Database: localhost/1415_WP/AWP Business Rule Name: WPA_Count By Planning user: wipoadmin.
    EnterData_Inner Processing Time:64
    EnterData_Inner Processing Time:15
    EnterData_Inner Processing Time:359
    EnterData_Inner Processing Time:2
    EnterData_Inner Processing Time:53
    EnterData_Inner Processing Time:4
    EnterData_Inner Processing Time:7
    EPM_ORACLE_INSTANCE (C:\Oracle\Middleware\user_projects\epmsystem1) is set from JVM property[EPM_ORACLE_INSTANCE].
    EPM_ORACLE_INSTANCE (C:\Oracle\Middleware\user_projects\epmsystem1) is set from JVM property[EPM_ORACLE_INSTANCE].
    EPM_ORACLE_INSTANCE (C:\Oracle\Middleware\user_projects\epmsystem1) is set from JVM property[EPM_ORACLE_INSTANCE].
    Setting HBR Mode to: 2
    In lookupBRLWA()
    Found HBR product = ESSBASE_PRODUCT
    Found HBR product = ESSBASE_PRODUCT
    Found HBR product = ESSBASE_PRODUCT
    HBR LWA Component = Default
    Default HBR = http://WIPLPRD01.svc.unicc.org:19000/eas
    In getDBDetails()
    Found HBR product = ESSBASE_PRODUCT
    In lookupBRLWA()
    Found HBR product = ESSBASE_PRODUCT
    Found HBR product = ESSBASE_PRODUCT
    =2013-11-05 20:35:08,234 WARN [ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)' com.hyperion.hbr.security.HbrSecurityAPI - Error retrieving user by identity
    - Error retrieving user by identity
    Embedded HBR initialized.
    EnterData_Inner Processing Time:6
    EnterData_Inner Processing Time:867
    [Tue Nov 05 20:35:33 CET 2013] Planning successfully notified HBR repository.
    EnterData_Inner Processing Time:7
    2013-11-05 20:40:38,613 INFO Thread-67 calcmgr.launch - Date/Time Started: 2013/11/05:20:40:38.606 CET Server/Application/Database: localhost/1415_WP/AWP Business Rule Name: NonPersonnel_Calc By Planning user: wipoadmin Values entered for run-time prompts: [Variable] Funds:"Regular"[Variable] Units:"0001"[Variable] Wrk_Scenario:"Work_Plan_2014"
    - Date/Time Started: 2013/11/05:20:40:38.606 CET Server/Application/Database: localhost/1415_WP/AWP Business Rule Name: NonPersonnel_Calc By Planning user: wipoadmin Values entered for run-time prompts: [Variable] Funds:"Regular"[Variable] Units:"0001"[Variable] Wrk_Scenario:"Work_Plan_2014"
    2013-11-05 20:40:47,241 INFO Thread-67 calcmgr.launch - Date/Time Ended: 2013/11/05:20:40:47.241 CET Server/Application/Database: localhost/1415_WP/AWP Business Rule Name: NonPersonnel_Calc By Planning user: wipoadmin.
    - Date/Time Ended: 2013/11/05:20:40:47.241 CET Server/Application/Database: localhost/1415_WP/AWP Business Rule Name: NonPersonnel_Calc By Planning user: wipoadmin.
    EnterData_Inner Processing Time:44
    EnterData_Inner Processing Time:2
    EnterData_Inner Processing Time:525
    EnterData_Inner Processing Time:1
    Reaquired task list lease: Tue Nov 05 20:41:49 CET 2013: 1383680509246

    I already replied there but it seems no moderator is willing to approve my reply so it never shows up.
    So I'll try replying in here instead:
    I never thought it could be an emulator issue, I thought I had done something wrong to begin with. So I take having performance issues with tiled layer is not a common problem I suppose?
    I'm using MOTODEV SDK platform, A1200 model (motorola).

  • Are there Issues with poor performance with Maverick OS,

    Are there issues with slow and reduced performance with Mavericks OS

    check this
    http://apple.stackexchange.com/questions/126081/10-9-2-slows-down-processes
    or
    this:
    https://discussions.apple.com/message/25341556#25341556
    I am doing a lot of analyses with 10.9.2 on a late 2013 MBP, and these analyses generally last hours or days. I observed that Maverick is slowing them down considerably for some reasons after few hours of computations, making it impossible for me to work with this computer...

  • Issues With GameCanvas Performance

    Hello, recently I've been toying with java mobile applications, but I've run accross a problem I cannot overcome.
    My LayerManager has two objects: the sprite and the tiled layer. Whenever I add the latter to my layer manager, I get 1-2 FPS when rendering the screen, but if I remove it and have only the sprite displayed, I get above 30 FPS.
    My layer has the following properties:
    TiledLayer mbg = new TiledLayer(15,20,tiles,16,16);
    Any help appreciated.
    PS: Getting 1-2 FPS on a crappy computer, but the same application running on a fast machine won't get past 11 FPS, although the main game loop is supposed to run at 20 FPS.
    Edited by: 860823 on 23/05/2011 12:13

    I already replied there but it seems no moderator is willing to approve my reply so it never shows up.
    So I'll try replying in here instead:
    I never thought it could be an emulator issue, I thought I had done something wrong to begin with. So I take having performance issues with tiled layer is not a common problem I suppose?
    I'm using MOTODEV SDK platform, A1200 model (motorola).

  • Issue with SQL Query with Presentation Variable as Data Source in BI Publisher

    Hello All
    I have an issue with creating BIP report based on OBIEE reports which is done using direct SQL. There is this one report in OBIEE dashboard, which is written using direct SQL. To create the pixel perfect version of this report, I am creating BIP data model using SQL Query as data source. The physical query that is used to create OBIEE report has several presentation variables in its where clause.
    select TILE4,max(APPTS), 'Top Count' from
    SELECT c5 as division,nvl(DECODE (C2,0,0,(c1/c2)*100),0) AS APPTS,NTILE (4) OVER ( ORDER BY nvl(DECODE (C2,0,0,(c1/c2)*100),0))  AS TILE4,
    c4 as dept,c6 as month FROM 
    select sum(case  when T6736.TYPE = 'ATM' then T7608.COUNT end ) as c1,
         sum(case  when T6736.TYPE in ('Call Center', 'LSM') then T7608.CONFIRMED_COUNT end ) as c2,
         T802.NAME_LEVEL_6 as c3,
         T802.NAME_LEVEL_1 as c4,
         T6172.CALENDARMONTHNAMEANDYEAR as c5,
         T6172.CALENDARMONTHNUMBERINYEAR as c6,
         T802.DEPT_CODE as c7
    from
         DW_date_DIM T6736 /* z_dim_date */ ,
         DW_MONTH_DIM T6172 /* z_dim_month */ ,
         DW_GEOS_DIM T802 /* z_dim_dept_geo_hierarchy */ ,
         DW_Count_MONTH_AGG T7608 /* z_fact_Count_month_agg */
    where  ( T802.DEpt_CODE = T7608.DEPT_CODE and T802.NAME_LEVEL_1 =  '@{PV_D}{RSD}' 
    and T802.CALENDARMONTHNAMEANDYEAR = 'July 2013'
    and T6172.MONTH_KEY = T7608.MONTH_KEY and T6736.DATE_KEY = T7608.DATE_KEY
    and (T6172.CALENDARMONTHNUMBERINYEAR between substr('@{Month_Start}',0,6)  and substr('@{Month_END}',8,13))
    and (T6736.TYPE in ('Call Center', 'LSM')) )
    group by T802.DEPT_CODE, T802.NAME_LEVEL_6, T802.NAME_LEVEL_1, T6172.CALENDARMONTHNAMEANDYEAR, T6172.CALENDARMONTHNUMBERINYEAR
    order by c4, c3, c6, c7, c5
    ))where tile4=3 group by tile4
    When I try to view data after creating the data set, I get the following error:
    Failed to load XML
    XML Parsing Error: mismatched tag. Expected: . Location: http://172.20.17.142:9704/xmlpserver/servlet/xdo Line Number 2, Column 580:
    Now when I remove those Presention variables (@{PV1}, @{PV2}) in the query with some hard coded values, it is working fine.
    So I know it is the PV that's causing this error.
    How can I work around it?
    There is no way to create equivalent report without using the direct sql..
    Thanks in advance

    I have found a solution to this problem after some more investigation. PowerQuery does not support to use SQL statement as source for Teradata (possibly same for other sources as well). This is "by design" according to Microsoft. Hence the problem
    is not because different PowerQuery versions as mentioned above. When designing the query in PowerQuery in Excel make sure to use the interface/navigation to create the query/select tables and NOT a SQL statement. The SQL statement as source works fine on
    a client machine but not when scheduling it in Power BI in the cloud. I would like to see that the functionality within PowerQuery and Excel should be the same as in Power BI in the cloud. And at least when there is a difference it would be nice with documentation
    or more descriptive errors.
    //Jonas 

  • [ADF-11.1.2] Locking issue with SQL 92

    I see one Locking issue with SQL92 Oracle ADF Application.
    ADF Version: [ADF-11.1.2]
    Database: Oracle 10g Express Edition
    Situation 1:
    With Following setting:
    File: Application Resource > Description > ADF META-INF > adf-config.xml
        <startup>
          <amconfig-overrides>
            <config:Database jbo.SQLBuilder="SQL92" jbo.locking.mode="optimistic"/>
          </amconfig-overrides>
        </startup>I have a page showing record 'x' of view object. I open same record on another page. Now I have same record showing on two different tabs of browser.
    1. I modify first record and save it. It worked... Got commited to database.
    2. I goto second tab and modify same record and tried to same it. It throws me an error - Another user has changed the row with primary key oracle.jbo.Key[38 ] . As expected...
    3. I then, reopen the same record on 3rd tab of browser. Modify it and tried to save it. It just hang... as if it is processing the record endlessly.
    If I see the Log:
    <BaseSQLBuilderImpl> <doEntitySelectForAltKey> [312] BaseSQLBuilderImpl Executing doEntitySelect ... (true)
    <BaseSQLBuilderImpl> <doEntitySelectForAltKey> [313] Generating new LOCK statement
    <BaseSQLBuilderImpl> <buildSelectString> [314] Built select: 'SELECT ID, CI_ID, COLUMN_NAME, DISPLAY_COLUMN_NAME, COLUMN_VALUE, CREATE_DATE, CREATE_BY FROM ESUSER.CI_AUDIT'
    <BaseSQLBuilderImpl> <doEntitySelectForAltKey> [315] Executing LOCK "SELECT ID, CI_ID, COLUMN_NAME, DISPLAY_COLUMN_NAME, COLUMN_VALUE, CREATE_DATE, CREATE_BY FROM ESUSER.CI_AUDIT WHERE ID=? FOR UPDATE"
    <BaseSQLBuilderImpl> <bindWhereAttrValue> [316] Where binding param 1: 38
    That's it.. nothing happens further.. If I execute above query on SQL Worksheet, it doesn't come up with the result. Just hang for something...
    SELECT ID, CI_ID, COLUMN_NAME, DISPLAY_COLUMN_NAME, COLUMN_VALUE, CREATE_DATE, CREATE_BY FROM ESUSER.CI_AUDIT WHERE ID='38' FOR UPDATE I can execute above query for other record of same table but not '38'. Even if I fire commit command to database, it is not working.
    I have to restart the database services to bring everything to normal state.
    Situation 2:
    With Oracle as Database :
        <startup>
          <amconfig-overrides>
            <config:Database jbo.SQLBuilder="Oracle" jbo.locking.mode="optimistic"/>
          </amconfig-overrides>
        </startup>Everything is working file. i.e. at step 3, record is getting modified successfully with following log:
    <OracleSQLBuilderImpl> <doEntitySelectForAltKey> [27] OracleSQLBuilder Executing doEntitySelect on: ESUSER.CI_AUDIT (true)
    <ADFLogger> <begin> Entity read all attributes
    <OracleSQLBuilderImpl> <buildSelectString> [28] Built select: 'SELECT ID, CI_ID, COLUMN_NAME, DISPLAY_COLUMN_NAME, COLUMN_VALUE, CREATE_DATE, CREATE_BY FROM ESUSER.CI_AUDIT CIAudit'
    <OracleSQLBuilderImpl> <doEntitySelectForAltKey> [29] Executing LOCK...SELECT ID, CI_ID, COLUMN_NAME, DISPLAY_COLUMN_NAME, COLUMN_VALUE, CREATE_DATE, CREATE_BY FROM ESUSER.CI_AUDIT CIAudit WHERE ID=? FOR UPDATE NOWAIT
    <ADFLogger> <addContextData> Entity read all attributes
    <OracleSQLBuilderImpl> <bindWhereAttrValue> [30] Where binding param 1: 38
    <ADFLogger> <addContextData> Entity read all attributes
    <ADFLogger> <end> Entity read all attributes
    <ADFLogger> <end> Lock Entity
    <ADFLogger> <begin> Before posting the entity's changes
    <ADFLogger> <begin> Updating audit columns
    <ADFLogger> <end> Updating audit columns
    <ADFLogger> <end> Before posting the entity's changes
    <OracleSQLBuilderImpl> <doEntityDML> [31] OracleSQLBuilder Executing, Lock 2 DML on: ESUSER.CI_AUDIT (Update)
    <OracleSQLBuilderImpl> <buildUpdateStatement> [32] UPDATE buf CIAudit>#u SQLStmtBufLen: 210, actual=60
    <OracleSQLBuilderImpl> <doEntityDML> [33] UPDATE ESUSER.CI_AUDIT CIAudit SET COLUMN_VALUE=? WHERE ID=?
    <ADFLogger> <begin> Entity DML
    <OracleSQLBuilderImpl> <bindUpdateStatement> [34] Update binding param 1: cip7ri1
    <OracleSQLBuilderImpl> <bindWhereAttrValue> [35] Where binding param 2: 38
    <ADFLogger> <addContextData> Entity DML
    <ADFLogger> <end> Entity DML
    Can any one please tell me, what is the issue with SQL92 setting ?
    Edited by: Anandsagar Sah on Mar 11, 2012 8:10 AM

    The framework works correctly in the Situation #1. Please, note that the locking statement in this case is "SELECT ... FOR UPDATE", but not "SELECT ... FOR UPDATE NOWAIT" (as it is in the Situation #2). When you entered the 2nd tab and tried to update the row, then the framework executed the locking statement and the row was locked (and it remained locked because the framework detected that another user had modified the row, so it stopped the processing and no COMMIT operation was executed). When you entered the 3rd tab and tried to update the row, then the framework tried to lock the row againg, but the locking statement was blocked by the existign lock and it started waiting on the lock from the 2nd tab. So this is expected behaviour.
    The interesting question is why you do not get any error in the Situation #2. In my opinion you should get an error because the locking statement from the 3rd tab should fail immediately (because the row should have been locked from the 2nd tab and the locking statement is with NOWAIT option). I suspect that when the DB is Oracle and you use Oracle SQLBuilder, then the ADF issues a DB savepoint at the beginning of the DML operation and rolls back to the savepoint is a case of some failure, so the 2nd tab has not left any lock. You can check this by setting on SQL trace on the DB server.
    Dimitar

  • DB-Library BCP issue with SQL Server 2014

    Hello,
    My application uses DB-Library (ntwdblib.dll) to communicate with SQL Server 2014. We are having issues calling bcp related functions like bcp_init which always returns FAIL status. Our application was working fine with SQL Server 2012 and all other previous
    SQL releases. But we are getting below error in SQL 2014,
    msg 4801, state 1, severity 16 : Insert bulk is not supported over this access protocol.
    Can anyone please help ?
    Thanks,
    Himanshu

    Hi Himanshu_kus,
    Is this still an issue, or can we close the thread?
    [Personal Site] [Blog] [Facebook]

  • Issue with SQL Developer connect to SQL server

    I'm using "SQL Developer 2.1.1.64.45" to work on a migration project which needs to convert a SQL server database to a Oracle 11g database. But I got an issue when I setup the SQL server connection. The SQL Developer let me connect by selecting a SQL server database name (For example: Northwind), but once connected, it always connected to "master" database instead. The "SQL Developer" is running on Windows 7 Professional (x64) platform. My Oracle database is 11g, and SQL server database is SQL 2005. And my SQL server instance name is "SQL2005". Anyone have ever experienced this problem? Thanks in advance.
    Edited by: user8276338 on Feb 8, 2011 1:05 PM

    Hi Bob,
    Thanks for the feedback, lets stick with SQL Developer 3.
    Correct me if I'm wrong,
    You attempted to migrate from SQL Server to Oracle including target generation and datamove in one go, by filling in each step of the migration wizard to the end.
    During the datamove you got
    ORA-01000:maximum open cursor exceeded
    So it looks like SQL Developer during the migration is not closing cursors fast enough and hits the maximum number of open cursors in your Oracle database.
    I think the default max open cursors is 300 in Oracle.
    There are a few things we can do here.
    You should be able to see the new migration project in your Migration Projects navigator.
    By navigating down the project tree to "Converted Database Objects" we can attempt the data move again by right clicking and choosing "Data Move".
    But first I would restart SQL Developer so as to free up any lingering open cursors.
    That may allow you to complete the data move, as the only cursors being open are being used in the data move and not some cursors which may have been left open from previous steps in the migration.
    Now from my perspective I would like to identify where are we leaving open the cursors, so I'm going to setup some testcases my end to see if I can replicate.
    From your perspective Id presume you just want to move on with the migration.
    So if the above (shutdown and attempt just the data move) doesnt workyou could
    A) Increase the MAX OPEN CURSORs on your Oracle databases so it complete the data move
    or
    B) Use the offline data move technique.
    A) Increase MAX OPEN CURSORs
    This wiki explains how to do that, looks like 1000 is fairly common, but even a much larger number is not a problem
    http://wiki.oracle.com/page/OPEN_CURSORS
    ALTER SYSTEM SET OPEN_CURSORS = 10000;
    OR
    B) Offline Data Move
    If you are moving large amounts of data (say > 1GB), then the standard data move (we call it online), which just uses JDBC to SELECT * FROM and INSERT INTO may not cut the mustard.
    In this case you can try using our offline technique. SQL Developer will generate a set of scripts for you.
    unload_script.bat will use SQL Servers BCP tool to dump out the table data into DAT files.
    oracle_ctl.bat will load the data in the DAT files into Oracle.
    As we know the names of all the tables, columns ,both SQL Server and Oracle, we can generate fairly good scripts.
    The benefit of this technique is large amounts of data can be migrated and you get to use tools designed to dump data and load in data, so you have better error logging and tweaking.
    To attempt this in the Migration Wizard , Data Move page, select offline.
    If you can describe your database a bit (number of tables, number of procedures, amount of data to migrate) I may be able to define my testcase better so I can replicate the issue.
    Thanks
    Dermot
    SQL Developer Team.

  • DB Read/Get Issues with SQL

    Hi,
    I am having issues with DB Get. Even after assigning the local variable in CRS script as "Date" type, I am unable to select it as a local variable in the "Add/Modify Button under the Filed Selection TAB.
    The Filed type for this in SQL DB is DateTime.
    Attached is the screenshot.
    Can somebody suggest what is the issue?

    Hi,
    I ran into this situation before. The only way I could work around it, was to create a view in SQL, which takes the date and convert it to a String (ex: 20091029). So, instead of doing the request against the table, I'm doing it against the view.
    After that, I'm able to retrieve the date as a String and convert it back to a date using the following Java code into a "SET" step:
    Assume that you have a variable named "nDateFromSQL" of type String
    SimpleDateFormat lFormatter = new SimpleDateFormat("yyyyMMdd");
    nTrandate = lFormatter.parse(nDateFromSQL);
    I hope that help !

  • Issue with a "perform in program" call.

    I am trying to do a call to a form in a zprogram. This call is being done inside an enhancement.  The reason for this is because I can't delcare forms in the enhancement.  Below is the issue:
    The parameters I am trying to pass are typed as follows (in the SAP enhancement - SAP code):
    types: begin of mrm_rbkpv.
            include structure rbkp_v.
    types: begin of mmcr_drseg.
            include structure drseg.
    types: mmcr_tdrseg type mmcr_drseg occurs 0.
    I have the following as the call to the form and the form declaration:
    PERFORM cancel_ret IN PROGRAM zcancel_retention USING e_trbkpv e_tdrseg[].
    FORM cancel_ret  USING p_tdrseg TYPE rbkp_v
                          it_tdrseG TYPE J_1IDRSEG.
    I am getting a run-time error saying:
        An exception occurred that is explained in detail below.
        The exception, which is assigned to class 'CX_SY_DYN_CALL_ILLEGAL_TYPE', was
         not caught in
        procedure "EXIT_SAPLMRMP_010" "(FUNCTION)", nor was it propagated by a RAISING
         clause.
        Since the caller of the procedure could not have anticipated that the
        exception would occur, the current program is terminated.
        The reason for the exception is:
        Call to FORM "CANCEL_RET" is incorrect:
        The actual parameter no. 1 has a different data type in the
        PERFORM than requested for the FORM "CANCEL_RET" in program
         "ZCANCEL_RETENTION".
    This is telling me that the system doesn't see  e_trbkpv being the same type as  p_tdrseg.  However, I can't see why they aren't the same time.  I also assume I will have the issue with the second parameter.  The table type (in my opinion) J_1IDRSEG should be the same type as mmcr_drseg.
    Any ideas?  The enhancement I am using is EXIT_SAPLMRMP_010 (LMR1M001).
    Regards,
    Aaron
    Edited by: Aaron Shover on Apr 11, 2009 7:21 PM

    >
    Aaron Shover wrote:
    > OK, Aditya, I added another type pool to my program and I can now use the same type that SAP is using.
    >
    > Thanks for pointing out the [obvious] solution that I was overlooking!
    >
    > Aaron
    Aaron, I was not aware of the type pools as mentioned I don't have access to the system at the moment. But type pool has type declarations as well, so what I meant was pulling out the 2 declarations that you need into your Z program could have solved the problem :). Which will happen now since you've included the type pools.
    Anyways good to know that you problem is solved.
    Cheers,
    Advait

  • Screen refresh issue with SQL Developer 1.5.5 on Vista 64 bit

    I am using the latest version of SQL Developer.
    I have screen refresh issues in sql developer. On scrolling up and down the display gets jumbled, some time screen do not display at all. Its making working with SQL Developer very difficult. I don't have such an issue with any of my other editors.
    Is this something specific to Vista? Is there any know solution to this issue.
    Thanks
    Edited by: user5899685 on Sep 1, 2009 11:14 AM

    Specific? Not really, but judging from the posts here Vista is more prone. It usually indicates incompatibility between Java and video drivers.
    If updating your JDK or video driver doesn't work or isn't an option, just disabling DirectDraw in \sqldeveloper\bin\sqldeveloper.conf usually works too:
    AddVMOption -Dsun.java2d.noddraw=trueHope that helps,
    K.

  • Issue with SQL Developer connecting to databases

    Hi all,
    I would be really grateful if anyone could advise me on the below issue.
    I have 64bit laptop running Windows 7 and I get the following error message when I try to connect via SQL Developer to an external database for work purposes:
    Status: Test Failed: C:\app\Terra-PC\product\product\11.2.0\dbhome_1\BIN\ocijdbc.dll: Can't load AMD64-bit .dll on a IA 32 -bit platform.
    Thanks for your help.
    Luke

    Hi,
    Actually, I resolved this issue with the help of a colleague. SQL Dev was not able to see my TNSnames file, because the Oracle_Home path was not defined. Something like that, anyway.
    Thanks,
    Luke

  • Any known issues with SQL DB Link Synonyms joining on encrypted columns

    Are there any known issues with accessing encrypted columns via a database link that is masked by a synonym?
    We are experiencing unexpected results when the encrypted column is anti-joined through a not exists, to a local encrypted column of the same datatype The encrypted columns are person ids. If the expected person id is hard coded, the results return correctly. The local database is 10.2.0.4.0 and the link is to a 10.2.0.3.0 RAC.
    Both enrollments and person_ids, below, are synonyms to the linked tables.
    ... From table_1 d
    where ...
    AND NOT EXISTS (SELECT 1
    FROM enrollments x,
    person_ids p
    WHERE x.person_demo = p.person_demo
    AND x.rept_inst = d.rept_inst
    AND x.demo_time_frame = d.term_deg_grant
    AND p.person_id_encrypted = '999999999')
    vs.
    ... From table_1 d
    where ...
    AND NOT EXISTS (SELECT 1
    FROM enrollments x,
    person_ids p
    WHERE x.person_demo = p.person_demo
    AND x.rept_inst = d.rept_inst
    AND x.demo_time_frame = d.term_deg_grant
    AND p.person_id_encrypted = d.person_id_encrypted)

    milazzo74 wrote:
    I am having the same problem...
    http://www.milazzo.com.br/teste/projetos.php
    It works fine in Firefox but loads forever in explorer 8...
    The cause of the problem is not the same.
    In your case it takes forever to load the thumbnails from flickr.com; the SpryDataSets without the loading of the thumbnails works as expected.
    Remember that ALL of the thumbnails for each 60 odd projects are downloaded from flickr, that is about 1800 thumbnails.
    Gramps

  • Performance Issue with sql query

    Hi,
    My db is 10.2.0.5 with RAC on ASM, Cluster ware version 10.2.0.5.
    With bsoa table as
    SQL> desc bsoa;
    Name                                      Null?    Type
    ID                                        NOT NULL NUMBER
    LOGIN_TIME                                         DATE
    LOGOUT_TIME                                        DATE
    SUCCESSFUL_IND                                     VARCHAR2(1)
    WORK_STATION_NAME                                  VARCHAR2(80)
    OS_USER                                            VARCHAR2(30)
    USER_NAME                                 NOT NULL VARCHAR2(30)
    FORM_ID                                            NUMBER
    AUDIT_TRAIL_NO                                     NUMBER
    CREATED_BY                                         VARCHAR2(30)
    CREATION_DATE                                      DATE
    LAST_UPDATED_BY                                    VARCHAR2(30)
    LAST_UPDATE_DATE                                   DATE
    SITE_NO                                            NUMBER
    SESSION_ID                                         NUMBER(8)
    The query
    UPDATE BSOA SET LOGOUT_TIME =SYSDATE WHERE SYS_CONTEXT('USERENV', 'SESSIONID') = SESSION_ID
    Is taking a lot of time to execute and in AWR reports also it is on top in
    1. SQL Order by elapsed time
    2. SQL order by reads
    3. SQL order by gets
    So i am trying a way to solve the performance issue as the application is slow specially during login and logout time.
    I understand that the function in the where condition cause to do FTS, but i can not think what other parts to look at.
    Also:
    SQL> SELECT COUNT(1) FROM BSOA;
      COUNT(1)
       7800373
    The explain plan for  "UPDATE BSOA SET LOGOUT_TIME =SYSDATE WHERE SYS_CONTEXT('USERENV', 'SESSIONID') = SESSION_ID" is
    {code}
    PLAN_TABLE_OUTPUT
    Plan hash value: 1184960901
    | Id  | Operation          | Name               | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | UPDATE STATEMENT   |                    |     1 |    26 | 18748   (3)| 00:03:45 |
    |   1 |  UPDATE            | BSOA |       |       |            |          |
    |*  2 |   TABLE ACCESS FULL| BSOA |     1 |    26 | 18748   (3)| 00:03:45 |
    Predicate Information (identified by operation id):
       2 - filter("SESSION_ID"=TO_NUMBER(SYS_CONTEXT('USERENV','SESSIONID')))
    {code}

    Hi,
    There are also triggers before update and AUDITS on this table.
    CREATE OR REPLACE TRIGGER B2.TRIGGER1
    BEFORE UPDATE
    ON B2.BSOA  REFERENCING OLD AS OLD NEW AS NEW
    FOR EACH ROW
    :NEW.LAST_UPDATED_BY   := USER    ;
    :NEW.LAST_UPDATE_DATE  := SYSDATE ;
    END;
    CREATE OR REPLACE TRIGGER B2.TRIGGER2
    BEFORE INSERT
    ON B2.BSOA  REFERENCING OLD AS OLD NEW AS NEW
    FOR EACH ROW
    :NEW.CREATED_BY        := USER ;
    :NEW.CREATION_DATE     := SYSDATE ;
    :NEW.LAST_UPDATED_BY   := USER    ;
    :NEW.LAST_UPDATE_DATE  := SYSDATE ;
    END;
    And also there is an audit on this table
    AUDIT UPDATE ON B2.BSOA BY ACCESS WHENEVER SUCCESSFUL;
    AUDIT UPDATE ON B2.BSOA BY ACCESS WHENEVER NOT SUCCESSFUL;
    And the sessionid column in BSOA has height balanced histogram.
    When i create an index i get the following error. As i am on 10g I can't use DDL_LOCK_TIMEOUT . I may have to wait for next down time.
    SQL> CREATE INDEX B2.BSOA_SESSID_I ON B2.BSOA(SESSION_ID) TABLESPACE B2 COMPUTE STATISTICS;
    CREATE INDEX B2.BSOA_SESSID_I ON B2.BSOA(SESSION_ID) TABLESPACE B2 COMPUTE STATISTICS
    ERROR at line 1:
    ORA-00054: resource busy and acquire with NOWAIT specified
    Thanks

  • Performance issue with SQL with different input data

    Hi Experts,
    I have an SQL query that uses three tables imtermination, imconnection, imconnectiondesign. Each of these tables have around 23Lakh, 11Lakh, 11Lakh rows respectively. There are appropriate indexes on these tables.
    Now there is a query:
    SELECT
    /*+ NO_MERGE(a) ORDERED USE_NL(c) */ c.objectid,
    c.typeid,
    c.transactionstatus,
    c.usersessionid,
    cd.objectid designid,
    c.reservationid,
    c.networkid,
    c.networktype,
    cd.inprojectid,
    cd.inprojecttype,
    cd.outprojectid,
    cd.outprojecttype,
    cd.asiteid,
    cd.asitetype,
    cd.anetworkelementid,
    cd.anetworkelementtype,
    cd.aportid,
    cd.aporttype,
    cd.achannelpath,
    c.asignaltype,
    cd.zsiteid,
    cd.zsitetype,
    cd.znetworkelementid,
    cd.znetworkelementtype,
    cd.zportid,
    cd.zporttype,
    cd.zchannelpath,
    c.zsignaltype,
    c.signaltype,
    c.visualkey,
    c.resourcestate,
    cd.assignmentstate,
    c.effectivefrom,
    cd.effectiveto,
    c.channelized,
    c.circuitusage,
    c.hardwired,
    c.consumedsignaltype,
    c.flowqualitycode,
    c.capacityused,
    c.percentused,
    c.maxcapacity,
    c.warningthreshold,
    c.typecode,
    cd.lastupdateddate,
    c.lastreconcileddate,
    c.bandwidth,
    c.unit
    FROM
    (SELECT terminatedid
    FROM imtermination t1
    WHERE t1.networkelementid = 9200150)
    a,
    imconnectiondesign cd,
    imconnection c
    WHERE cd.objectid = a.terminatedid
    AND c.objectid = cd.connectionid
    AND(SUBSTR('10000000000000000000011111111111110000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000', c.consumedsignaltype + 1, 1) = '1' OR SUBSTR('10000000000000000000011111111111110000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000', c.signaltype + 1, 1) = '1')
    AND c.typeid = '$131'
    AND cd.assignmentstate IN(2, 3)
    The above query takes around 70 secs to execute when input t1.networkelementid = 9200150. Moreover i have observed in the enterprise manager that this has very high i/o wait time.
    Now the same query takes around 5 secs to execute when the input t1.networkelementid = 42407448. Both these obejcts with id 9200150 and 42407448 have almost same number of rows and output and without any condition each have 6500 rows in all the three tables.
    The execution plan for both these queries with t1.networkelementid = 9200150 and t1.networkelementid = 42407448 is also coming same.
    The rows that are corresponding to t1.networkelementid = 9200150 in these three tables are the result of the data created through the application over a period of time. While in case of rows corresponding to t1.networkelementid = 42407448 i have created manually and are contiguous in the three tables.
    Does the above behavior is because in case of t1.networkelementid = 42407448 the rows that corresponds to it are not contiguous as they are created over a period of time ?
    Execution Statistics
    Total     Per Execution     Per Row
    Executions     1     1     0.02
    CPU Time (sec)     0.91     0.91     0.02
    Buffer Gets     11943     11943.00     238.86
    Disk Reads     4804     4804.00     96.08
    Direct Writes     0     0.00     0.00
    Rows     50     50.00     1
    Fetches     5     5.00     0.10
              User I/O Waits(98.7%)          
                   CPU(1.3%)
    Enterprise manager shows high db file scattered read in case of t1.networkelementid = 9200150, the input for which it is taking 70 secs.
    Request experts to provide some pointers to fix this issue as i am not an expert in db tuning.
    Thanks in advance for your help.
    Regards

    Hi David,
    Please find below the output:
    SQL> SELECT table_name, num_rows, last_analyzed
      2    FROM all_tables
      3   WHERE table_name IN ('IMTERMINATION', 'IMCONNECTIONDESIGN', 'IMCONNECTION')
      4  /
    TABLE_NAME                       NUM_ROWS LAST_ANAL
    IMTERMINATION                     2338746 19-SEP-11
    IMCONNECTIONDESIGN                1129298 19-SEP-11
    IMCONNECTION                      1169373 19-SEP-11
    IMTERMINATION                       19852 13-SEP-11
    IMCONNECTIONDESIGN                   6820 13-SEP-11
    IMCONNECTION                         9926 13-SEP-11
    6 rows selected.
    SQL> SELECT table_name, index_name,num_rows, last_analyzed
      2    FROM all_indexes
      3   WHERE table_name IN ('IMTERMINATION', 'IMCONNECTIONDESIGN', 'IMCONNECTION')
      4  order by table_name,index_name
      5  /
    TABLE_NAME                     INDEX_NAME                       NUM_ROWS LAST_ANAL
    IMCONNECTION                   IMCONNECTION_A_NE                    9925 13-SEP-11
    IMCONNECTION                   IMCONNECTION_A_NE                 1169154 19-SEP-11
    IMCONNECTION                   IMCONNECTION_A_PORT                 84743 19-SEP-11
    IMCONNECTION                   IMCONNECTION_A_PORT                  3371 13-SEP-11
    IMCONNECTION                   IMCONNECTION_A_SITE               1169373 19-SEP-11
    IMCONNECTION                   IMCONNECTION_A_SITE                  9926 13-SEP-11
    IMCONNECTION                   IMCONNECTION_NET                        0 19-SEP-11
    IMCONNECTION                   IMCONNECTION_NET                       12 13-SEP-11
    IMCONNECTION                   IMCONNECTION_PK                      9926 13-SEP-11
    IMCONNECTION                   IMCONNECTION_PK                   1169373 19-SEP-11
    IMCONNECTION                   IMCONNECTION_RES                        0 13-SEP-11
    IMCONNECTION                   IMCONNECTION_RES                        0 19-SEP-11
    IMCONNECTION                   IMCONNECTION_ST                         2 13-SEP-11
    IMCONNECTION                   IMCONNECTION_ST                        60 19-SEP-11
    IMCONNECTION                   IMCONNECTION_TYPEID                     4 13-SEP-11
    IMCONNECTION                   IMCONNECTION_TYPEID                    64 19-SEP-11
    IMCONNECTION                   IMCONNECTION_UR                     26880 19-SEP-11
    IMCONNECTION                   IMCONNECTION_UR                         3 13-SEP-11
    IMCONNECTION                   IMCONNECTION_VK                      9810 13-SEP-11
    IMCONNECTION                   IMCONNECTION_VK                   1191866 19-SEP-11
    IMCONNECTION                   IMCONNECTION_Z_NE                 1169173 19-SEP-11
    IMCONNECTION                   IMCONNECTION_Z_NE                    9925 13-SEP-11
    IMCONNECTION                   IMCONNECTION_Z_PORT                 84092 19-SEP-11
    IMCONNECTION                   IMCONNECTION_Z_PORT                  3370 13-SEP-11
    IMCONNECTION                   IMCONNECTION_Z_SITE                  9926 13-SEP-11
    IMCONNECTION                   IMCONNECTION_Z_SITE               1169373 19-SEP-11
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_CON            1129298 19-SEP-11
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_CON               6820 13-SEP-11
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_PK             1129298 19-SEP-11
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_PK                6820 13-SEP-11
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_ST                6820 13-SEP-11
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_ST             1129298 19-SEP-11
    IMTERMINATION                  IMTERMINATION_ID                    19852 13-SEP-11
    IMTERMINATION                  IMTERMINATION_ID                  2279477 19-SEP-11
    IMTERMINATION                  IMTERMINATION_NE                    19850 13-SEP-11
    IMTERMINATION                  IMTERMINATION_NE                  2327175 19-SEP-11
    IMTERMINATION                  IMTERMINATION_PORT                 168835 19-SEP-11
    IMTERMINATION                  IMTERMINATION_PORT                   6741 13-SEP-11
    IMTERMINATION                  IMTERMINATION_SITE                  19852 13-SEP-11
    IMTERMINATION                  IMTERMINATION_SITE                2391415 19-SEP-11
    40 rows selected.
    SQL> select table_name,index_name,column_name,column_position
      2    FROM all_ind_columns
      3   WHERE table_name IN ('IMTERMINATION', 'IMCONNECTIONDESIGN', 'IMCONNECTION')
      4  order by table_name,index_name, column_position
      5  /
    TABLE_NAME                     INDEX_NAME
    COLUMN_NAME
    COLUMN_POSITION
    IMCONNECTION                   IMCONNECTION_A_NE
    ANETWORKELEMENTID
                  1
    IMCONNECTION                   IMCONNECTION_A_NE
    ANETWORKELEMENTID
                  1
    IMCONNECTION                   IMCONNECTION_A_PORT
    APORTID
                  1
    IMCONNECTION                   IMCONNECTION_A_PORT
    APORTID
                  1
    IMCONNECTION                   IMCONNECTION_A_SITE
    ASITEID
                  1
    IMCONNECTION                   IMCONNECTION_A_SITE
    ASITEID
                  1
    IMCONNECTION                   IMCONNECTION_NET
    NETWORKID
                  1
    IMCONNECTION                   IMCONNECTION_NET
    NETWORKID
                  1
    IMCONNECTION                   IMCONNECTION_PK
    OBJECTID
                  1
    IMCONNECTION                   IMCONNECTION_PK
    OBJECTID
                  1
    IMCONNECTION                   IMCONNECTION_RES
    RESERVATIONID
                  1
    IMCONNECTION                   IMCONNECTION_RES
    RESERVATIONID
                  1
    IMCONNECTION                   IMCONNECTION_ST
    RESOURCESTATE
                  1
    IMCONNECTION                   IMCONNECTION_ST
    RESOURCESTATE
                  1
    IMCONNECTION                   IMCONNECTION_TYPEID
    TYPEID
                  1
    IMCONNECTION                   IMCONNECTION_TYPEID
    TYPEID
                  1
    IMCONNECTION                   IMCONNECTION_UR
    USERSESSIONID
                  1
    IMCONNECTION                   IMCONNECTION_UR
    USERSESSIONID
                  1
    IMCONNECTION                   IMCONNECTION_VK
    VISUALKEY
                  1
    IMCONNECTION                   IMCONNECTION_VK
    VISUALKEY
                  1
    IMCONNECTION                   IMCONNECTION_Z_NE
    ZNETWORKELEMENTID
                  1
    IMCONNECTION                   IMCONNECTION_Z_NE
    ZNETWORKELEMENTID
                  1
    IMCONNECTION                   IMCONNECTION_Z_PORT
    ZPORTID
                  1
    IMCONNECTION                   IMCONNECTION_Z_PORT
    ZPORTID
                  1
    IMCONNECTION                   IMCONNECTION_Z_SITE
    ZSITEID
                  1
    IMCONNECTION                   IMCONNECTION_Z_SITE
    ZSITEID
                  1
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_CON
    CONNECTIONID
                  1
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_CON
    CONNECTIONID
                  1
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_PK
    OBJECTID
                  1
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_PK
    OBJECTID
                  1
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_ST
    ASSIGNMENTSTATE
                  1
    IMCONNECTIONDESIGN             IMCONNECTIONDESIGN_ST
    ASSIGNMENTSTATE
                  1
    IMTERMINATION                  IMTERMINATION_ID
    TERMINATEDID
                  1
    IMTERMINATION                  IMTERMINATION_ID
    TERMINATEDID
                  1
    IMTERMINATION                  IMTERMINATION_NE
    NETWORKELEMENTID
                  1
    IMTERMINATION                  IMTERMINATION_NE
    NETWORKELEMENTID
                  1
    IMTERMINATION                  IMTERMINATION_PORT
    PORTID
                  1
    IMTERMINATION                  IMTERMINATION_PORT
    PORTID
                  1
    IMTERMINATION                  IMTERMINATION_SITE
    SITEID
                  1
    IMTERMINATION                  IMTERMINATION_SITE
    SITEID
                  1
    40 rows selected.
    Plan without sql hints:
    SQL> select * from table(dbms_xplan.display)
      2  /
    PLAN_TABLE_OUTPUT
    Plan hash value: 2493901029
    | Id  | Operation                     | Name                  | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT              |                       |    40 |  9960 |  6316   (1)| 00:01:16 |
    |   1 |  NESTED LOOPS                 |                       |    40 |  9960 |  6316   (1)| 00:01:16 |
    |   2 |   NESTED LOOPS                |                       |  1359 |   160K|  3592   (1)| 00:00:44 |
    |   3 |    TABLE ACCESS BY INDEX ROWID| IMTERMINATION         |  1359 | 16308 |   915   (1)| 00:00:11 |
    |*  4 |     INDEX RANGE SCAN          | IMTERMINATION_NE      |  1359 |       |     6   (0)| 00:00:01 |
    |*  5 |    TABLE ACCESS BY INDEX ROWID| IMCONNECTIONDESIGN    |     1 |   109 |     2   (0)| 00:00:01 |
    |*  6 |     INDEX UNIQUE SCAN         | IMCONNECTIONDESIGN_PK |     1 |       |     1   (0)| 00:00:01 |
    |*  7 |   TABLE ACCESS BY INDEX ROWID | IMCONNECTION          |     1 |   128 |     2   (0)| 00:00:01 |
    |*  8 |    INDEX UNIQUE SCAN          | IMCONNECTION_PK       |     1 |       |     1   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       4 - access("T1"."NETWORKELEMENTID"=9200150)
       5 - filter("CD"."ASSIGNMENTSTATE"=2 OR "CD"."ASSIGNMENTSTATE"=3)
       6 - access("CD"."OBJECTID"="TERMINATEDID")
       7 - filter((("C"."CONSUMEDSIGNALTYPE"=21 OR "C"."CONSUMEDSIGNALTYPE"=22 OR
                  "C"."CONSUMEDSIGNALTYPE"=23 OR "C"."CONSUMEDSIGNALTYPE"=24 OR "C"."CONSUMEDSIGNALTYPE"=25 OR
                  "C"."CONSUMEDSIGNALTYPE"=26 OR "C"."CONSUMEDSIGNALTYPE"=27 OR "C"."CONSUMEDSIGNALTYPE"=28 OR
                  "C"."CONSUMEDSIGNALTYPE"=29 OR "C"."CONSUMEDSIGNALTYPE"=30 OR "C"."CONSUMEDSIGNALTYPE"=31 OR
                  "C"."CONSUMEDSIGNALTYPE"=32 OR "C"."CONSUMEDSIGNALTYPE"=33) OR ("C"."SIGNALTYPE"=21 OR
                  "C"."SIGNALTYPE"=22 OR "C"."SIGNALTYPE"=23 OR "C"."SIGNALTYPE"=24 OR "C"."SIGNALTYPE"=25 OR
                  "C"."SIGNALTYPE"=26 OR "C"."SIGNALTYPE"=27 OR "C"."SIGNALTYPE"=28 OR "C"."SIGNALTYPE"=29 OR
                  "C"."SIGNALTYPE"=30 OR "C"."SIGNALTYPE"=31 OR "C"."SIGNALTYPE"=32 OR "C"."SIGNALTYPE"=33)) AND
                  "C"."TYPEID"='$131')
       8 - access("C"."OBJECTID"="CD"."CONNECTIONID")
    32 rows selected.

Maybe you are looking for