SQL Query Details in AWR Report

Hi
In AWR Report i found that there are few SQL queries that have full table scans
how can we drill about this and find which table have full scan
yes with Explain plan we can do this but is there any other way in Oracle 11g
please let me know
CHeers

Saggy wrote:
In AWR Report i found that there are few SQL queries that have full table scans
how can we drill about this and find which table have full scan
yes with Explain plan we can do this but is there any other way in Oracle 11g
please let me know
What, exactly, are you looking at in the AWR report that allows you to decide that some SQL statements are doing full tablescans but, at the same time, doesn't show you which tables are being scanned ?
If the statement is visible in the "SQL ordered by ... " sections of the report then the execution plans and workloed for the statement is also in the AWR. You can access it either from Enterprise Manager, or by running the $ORACLE_HOME/rdbms/admin/awrsqrpt.sql report.
Regards
Jonathan Lewis
http://jonathanlewis.wordpress.com
Author: <b><em>Oracle Core</em></b>

Similar Messages

  • Extracting the Logical sql query for the specified report  in OBIEE 11g

    Hi ,
    I want to extract the logical SQL Query for the Particular report in OBIEE 11.1.1.5.
    Any pointers related to this will be very helpful.
    Thanks,
    Sonali

    for a try please add Logical sql view to ur report it will dispaly the Logical sql for that Report..
    Hope it will helps you.

  • SQL Query to get statistics report

    Hi Experts,
    I need to get a report for CPU utilization,Memory Usage,Event Waits, Connection Spool and Shared Spool for a given query.
    Need some tips from you to get that report.
    Thanks,

    Its not something to trace my slow running sql query.
    I need to provide a report regarding Database Statistics on a specific process from front end PHP.
    Previously, i have provided you the different environment Oracle Version, here is the exact version in which i need to generate the report.
    BANNER                                                                         
    Oracle Database 11g Enterprise Edition Release 11.1.0.7.0 - 64bit Production   
    PL/SQL Release 11.1.0.7.0 - Production                                         
    CORE     11.1.0.7.0     Production                                                     
    TNS for Solaris: Version 11.1.0.7.0 - Production                               
    NLSRTL Version 11.1.0.7.0 - Production                                          This Database server is controlled by Client and having just limited access (not able to access the Trace Files).
    Can someone tell me to generate the requested report using some v$ Views.
    Thanks,
    Edited by: DharanV on Apr 15, 2010 8:01 PM
    added some more details to make it much clear

  • Concatenate results SQL query and CASE use Report Builder Reporting Services

    I need to concatenate the results from a SQL query that is using CASE.  The query is listed below.  I do not need permitsubtype but I need to concatenate the results from the permittype. 
    I tried deleting the permitsubtype query and it would not run correctly.  Please see the query and diagram below.  Any help is appreciated.
    select  PERMIT_NO
    ,(case when
      ISNULL(PERMITTYPE,'') = ''
      then 'Unassigned'
      else (select LTRIM(RTRIM(PERMITTYPE)))
      END) AS PERMITTYPE
    ,(case when
      ISNULL(PERMITSUBTYPE,'') = ''
      then 'Unassigned'
      else (select LTRIM(RTRIM(PERMITSUBTYPE)))
      END) AS PERMITSUBTYPE
     ,ISSUED
     ,APPLIED
     ,STATUS 
     ,SITE_ADDR 
     ,SITE_APN
     ,SITE_SUBDIVISION
     ,OWNER_NAME
     ,CONTRACTOR_NAME
     ,ISNULL(JOBVALUE,0) AS JOBVALUE
     ,FEES_CHARGED
     ,FEES_PAID
    ,BLDG_SF
    from Permit_Main
    where ISSUED between @FromDate and @ToDate

    Hi KittyCat101,
    As per my understanding, you used case when statement in the query, you do not need to display permitsubtype in the report, but when you tried to delete permitsubtype from the query, it could not run correctly. In order to improve the efficiency of troubleshooting,
    I need to ask several questions:
    “I tried deleting the permitsubtype query and it would not run correctly.” As we can see, it has no effect to delete permitsubtype from the query you provided, could you please provide complete sql query for the report?
    Could you please provide detailed information about the report? I would be appreciated it if you could provide sample data and screenshot of the report.
    Please provide some more detailed information of your requirements.
    This may be a lot of information to ask for at one time. However, by collecting this information now, it will help us move more quickly toward a solution.
    Thanks,
    Wendy Fu

  • SQL Query Too Large For Report Region

    Oracle Friends:
    I have a SQL query that is 24,000 characters long. APEX fails when I try to create a report using this query, probably because it is too long.
    I get an "ORA-01461: can bind a LONG value only for insert into a LONG column" after I paste it and try to go to the next page.
    Any ideas? I can't make my query any smaller without creating intermediate tables.
    Any help would be most appreciated.
    Regards,
    Rich Locus

    Hi,
    If possible, try to reduce the no. of characters from your SQL query. Ex. use shorter aliases etc in your query. Also, as suggested above, create some views which can form a part of your query and then use those views in your main query to reduce the total no. of characters.
    The report region source can take some limited no. of characters only. Exact figure is not known to me.
    Try the above suggestion and see if this works or not.
    Regards,
    Mangal

  • SQL Query based BI Pub report - Taking too long to produce the output

    Hi All,
    I was trying to produce a BI Publisher based report through enterprise edition of BI Publisher 10.1.3.4
    Its a sql query based report and it has around 20 columns and it has around 1 lakh records.
    The query actually takes only 2 seconds to execute in the database but when we execute from BI Publisher it takes a long time and also it times out most of the time
    Is there something I am missing in the configuration options ?
    Thanks
    Shasi

    I am facing the same problem as well. I am using the Publisher Web service API to run a report with 1 Million records. This report is configured to use OBIEE. It takes a lot of time to generate the report ( around 30 Mins) and even though OBIEE generates the data, my web service client either timesout. Even after increasing the timeout, a 500 internal server error is thrown . Does anyone know of a solution to this.
    Thanks

  • Executing PL-SQL Query before running a Report

    Hi Guys,
    Can i use a Run a Pl-Sql Query every time before executing a report. Like if i am opening a report then the pl-sql Query should run before it.
    Thanks
    Rondo.

    Try with Evaluate as one of the column's expression.. so that we can limit to specific report..
    or
    Use Connection Pool->Connection Pool Scripts tab->use 'Execute before query'
    Since we can set the repository variables using advanced tab.. the same variable we may validate using Connection pool scripts tab.
    This might be more dev work..
    Edited by: Srini VEERAVALLI on Dec 17, 2012 9:00 PM

  • How to execute SQL Query from the Crystal report X1

    Dear All,
    I am using crystal report X1. In my application am creating run time MS Access tables and giving table name at run time based on my requirement . From these tables I want to fetch data based on some condition and to display using crystal report X1. I have never used the SQL Queries in the Crystal reports. Please help me out.
    Thanks and Regards,
    Rahaneef T

    Please note;
    This forum is dedicated to all other development-related questions which are not directly addressed by other forums. This includes Business Objects SDKs, products, or technologies which do not fall under BusinessObjects Enterprise, BusinessObjects Edge, Crystal Reports Server, or Crystal Reports (for example Desktop Intelligence SDK, Universe Designer SDK, Portal Integration Kits, Java User Function Libraries, and other third party technologies or development languages).
    This looks more like a Crystal Reports design issue?
    Ludek

  • SQL Query to BI Publisher Report

    I'm new to BI Publisher. My results from my SQL query did not load properly into BI Publisher. Below is the XML. Can someone help? Thanks!
    <?xml version="1.0" ?>
    - <RESULTSET>
    - <ROWSET id="0">
    - <ROW id="1">
    - <COLUMN NAME="ID">
    - <![CDATA[
    12345
      ]]>
    </COLUMN>
    - <COLUMN NAME="NAME">
    - <![CDATA[
    Mary Jones
      ]]>
    </COLUMN>
    <COLUMN NAME="Gender">F</COLUMN>
    <COLUMN NAME="Address">10-10 203rd Street</COLUMN>
    <COLUMN NAME="City">New York</COLUMN>
    <COLUMN NAME="State">NY</COLUMN>
    <COLUMN NAME="Zip">10013</COLUMN>
    - <COLUMN NAME="Notes">
    - <![CDATA[
    Pending application submission.
      ]]>
    </COLUMN>
    <COLUMN NAME="Birth Date">8/1/1975</COLUMN>
    </ROW>
    </ROWSET>
    </RESULTSET>

    Hi Sonal,
    a possible solution for this can be the use of a lead function (take a look once here where the function is explained http://www.oracle-base.com/articles/misc/LagLeadAnalyticFunctions.php)
    Hope this can help you out.
    Kr
    A

  • Handling DST in SQL Query for UCCX Custom Report

    We wrote all custom reports for one of the call centers using our UCCX deployment.  One problem we see we will hit in the future is DST.  We suggested they use UTC but they wanted to see the call data based off of EST timezone.  Right now we are okay because we use -5 to get the correct data but come March we are wondering how to address the issue.  What options do we have?  How are other people handling DST with the SQL queries for custom reporting?  I see that the HR client will determine this based off of the local computer time then gives you the option to use UTC.  We have all of our queries in an Excel document that the customer just needs to open and select Refresh All to update their data.
    Thanks

    "case-when" statements are evaluated in order.
    so you must do something like this:
    SELECT
    CASE WHEN <is not number>THEN 'N'
    CASE WHEN <is greater than 0>THEN 'Y'
    Now "<is greater than 0>" will always have number for input, can't get "not number" error there.
    See this thread:
    Re: regular expression: integer is between N..M
    Edited by: CharlesRoos on May 27, 2010 5:03 AM

  • Sql query to create a report

    I am trying to extract a report for some pois, unfortunately I don't know how to formulate the query properly. Some data samples together with the rules for the report are described below:
    with my_tab as (select 1 id, 'ACME' supplier, 1 poi, 'A' attr1, 'B' attr2 from dual union all
    select 2 id, 'TOMA' supplier, 2 poi, 'C' attr1, 'D' attr2 from dual union all
    select 3 id, 'ACME' supplier, 3 poi, 'A' attr1, 'B' attr2 from dual union all
    select 4 id, 'TOMA' supplier, 3 poi, 'C' attr1, 'D' attr2 from dual union all
    select 5 id, 'ACME' supplier, 4 poi, null attr1, null attr2 from dual union all
    select 6 id, 'TOMA' supplier, 4 poi, 'C' attr1, 'D' attr2 from dual union all
    select 7 id, 'ACME' supplier, 5 poi, null attr1, 'B' attr2 from dual union all
    select 8 id, 'TOMA' supplier, 5 poi, 'C' attr1, 'D' attr2 from dual union all
    select 9 id, 'ACME' supplier, 6 poi, null attr1, null attr2 from dual union all
    select 10 id, 'TOMA' supplier, 6 poi, null attr1, 'D' attr2 from dual)
    rules for the resultset:
    a) each distinct poi has to occur exactly once
    b) if there is more than one record having the same poi id, the attributes from supplier ACME are preferred
    c) if ACME is not able to provide an attribute, the supplier TOMA has to step in
    The result should look like this:
    poi | attr1 | att2
    1 | A | B |
    2 | C | D |
    3 | A | B |
    4 | C | D |
    5 | C | B |
    6 | null | D |
    Edited by: user8914294 on Dec 21, 2009 11:58 AM
    Edited by: user8914294 on Dec 21, 2009 11:59 AM

    Hi,
    Welcome to the forum!
    Here's one way:
    SELECT       poi
    ,       MAX (attr1) KEEP (DENSE_RANK FIRST ORDER BY CASE
                                                                       WHEN  attr1  IS NOT NULL     THEN 1
                                                                   END
                                  ,           CASE  supplier
                                            WHEN  'ACME'  THEN  1
                                            WHEN  'TOMA'  THEN  2
                                                                   END
                      ) AS attr_1
    ,       MAX (attr2) KEEP (DENSE_RANK FIRST ORDER BY CASE
                                                                       WHEN  attr2  IS NOT NULL     THEN 1
                                                                   END
                                  ,           CASE  supplier
                                            WHEN  'ACME'  THEN  1
                                            WHEN  'TOMA'  THEN  2
                                                                   END
                      ) AS attr_2
    FROM       my_tab
    GROUP BY  poi
    ORDER BY  poi
    ;This does not rely on the fact that there are only two suppliers, or that the combination (poi, supplier) is unique, or that the order of preference for suppliers is the same as alphabetic order.
    This is an example of a Top-N Query , where you want N items (N=1 in this case) from the top of a sorted list. The problem is, how can we sort the values so that the more desirable ones come at the top of the list?
    There are two things that make one value more desirable than another:
    (1) Non-NULL values are better than NULL. After that:
    (2) Rows where supplier='ACME' are more desireable than rows where supplier='TOMA'.
    As it happens, both of these require CASE expressions (or siomething similar, like NVL2) to sort.
    Thanks for posting the sample data in such a useful format! That helps a lot.

  • SQL query problem using analytical/report function

    Hello there,
    I am having some problem writing my query. I have this table below:
                  create table t (priority number,
                                  plannedamount number,
                                  availablepieces number,
                                  material_id varchar2(20))
    insert into t values (1, 15, 30, 'A');
    insert into t values (2, 20, 30, 'A');
    insert into t values (3, 5, 30, 'A');
    insert into t values (4, 8, 30, 'A');
    insert into t values (5, 4, 30, 'A');
    insert into t values (1, 2, 10, 'B');     PRIORITY|     PLANNED AMOUNT|AVAILABLE PIECES |     MATERIAL_ID
         1      15     30 A     
         2      20     30 A
         3      5     30 A
         4      8 30 A
         5      4     30 A
         1      2     30 B .
    Each line is a customer order ordering a material. I am grouping by material and ordering it by priority. I want to display a new column called pieces not reserved yet. This column will show that if the order can be fully reserved for that current order ordering by priority.
    If the row can be reserved it will substract and bring it to the next row. If it cannot the pieces not reserved will remain the same.
    I've tried using sum(), lead(), first(), lag(), etc but I still cannot get the correct result.
         PRIORITY|     PLANNED AMOUNT|PIECES NOT RESERVED YET |     MATERIAL_ID
         1      15     30 A     
         2      20     15 A
         3      5     15 A
         4      8     10 A
         5      4     2 A
         1      2     30 B
    Can anyone elaborate or have any hints on what method to use to create this column?
    Thanks. .
    Edited by: 998373 on Apr 5, 2013 11:42 AM
    Edited by: 998373 on Apr 5, 2013 11:43 AM

    From 10.x on
    with t(PRIORITY, PLANNED_AMOUNT,AVAILABLE_PIECES , MATERIAL_ID) as
    select      1, 15, 30, 'A' from dual union all
    select 2, 20, 30, 'A' from dual union all
    select 3, 5, 30, 'A' from dual union all
    select 4, 8, 30, 'A' from dual union all
    select 5, 4, 30, 'A' from dual union all
    select 1, 2, 30, 'B'  from dual
    select
      MATERIAL_ID
    , PRIORITY
    , PLANNED_AMOUNT
    , AVAILABLE_PIECES PIECES_NOT_RESERVED_YET
    from t
    model
    partition by (material_id)
    dimension by (PRIORITY)
    measures (
      PLANNED_AMOUNT
    , AVAILABLE_PIECES
    rules (
    AVAILABLE_PIECES[priority>1] order by priority=
      case when PLANNED_AMOUNT[cv()-1] <= AVAILABLE_PIECES[cv()-1]
           then AVAILABLE_PIECES[cv()-1] - PLANNED_AMOUNT[cv()-1]
           else AVAILABLE_PIECES[cv()-1]
      end
    MATERIAL_ID     PRIORITY     PLANNED_AMOUNT     PIECES_NOT_RESERVED_YET
    A     1     15     30
    A     2     20     15
    A     3     5     15
    A     4     8     10
    A     5     4     2
    B     1     2     30

  • SAP Crystal Report (2008) through SQL Query parameters

    Hi,
    I Created a report in Crystal report (2008) based on Sql Query. I created parameters in SQL query prompt only (all single valued).
    Based on this I need to show the data in detail section.
    For Graph, I used another SQL query, and added one subreport to the Main report header section. Since this subreport is also using the SQL query prompts for taking parameters.
    Since both the reports are using same set of parameters. I mapped Main report parameters to sub-report parameters.
    So Now structure is like,
    In a report there is one subreport.
    Main report ....SQL query generates parameter prompt..same parameters is passed to subreport.
    In subreport there are sql generated prompts. and we mapped that prompts to main report parameter prompts.
    Now it is running fine from crystal report, but not from CMC. It is not showing the graph.
    Made Two Experiment:
    1. To check subreport is running or not , Mannualy put my name in sub report--working fine.(CMC)
    2. To check the parameters are correctly mapped--printed the value in subreport--Showing all the parameters value from CMC
    but it is not running the SQL query of that sub report.
    Any suggestion ?? Or is there anyoption to check?? Or a CMC setting.
    Please suggest and respond..
    Thank you in advance.!!

    Hi Rajeev,
    This is Crystal reports development community, you said the report is working fine in Crystal. it is problem in CMC. So the issue is at BI Server.
    So i think you need to create the thread in the below community.
    BI Platform
    --Naga

  • Error in report when executing pl/sql function body returning sql query.

    Hi,
    I have used the pl/sql function body returning sql query for creating a report. I have created a datepicker(
    P10_TASK_DATE) which can be submitted.The code is as below
    DECLARE
    v_sql varchar2(3000);
    BEGIN
    if :P10_TASK_DATE is not null THEN
    v_sql:='select
          * from tasks';
    return v_sql;
    else
    v_sql:='select * from discovery';
    return v_sql;
    END IF;
    END;if the date field is empty "select * from discovery" is executed and report is getting generated. But when we give a
    date using date picker the page is submitted and i get "report error: ORA-01403: no data found" even
    though the "tasks" table has data in it. Plz help
    Thanks,
    TJ

    hi
    Please try this
    1. Create 2 region
    1st region source=
    select * from tasks'
    go to the tab -> condition =
    item NOT NULL
    EXpression1 =:P10_TASK_DATE
    this will run whenever the item have any date
    2. open your 2 nd region source code= select * from discovery
    put the condition
    item is  NULL
    EXpression1 =:P10_TASK_DATE
    thanks
    Mark Wyatt

  • How to pass parameter value as "where [fieldname] = [fieldvalue]" in sql query under query type in SSRS report?

    I am having trouble with passing dynamic string to sql query for executing SSRS reports.
    I am using oracle database and I want to pass where clause parameter as "where LAND_NR = 6" to my select query.
    For example: I want to execute Select * from employee :p_where.
    where p_where parameter holds value "where LAND_NR = 6"
    So it will treat as "Select * from employee where LAND_NR = 6" statement which will give me the list of records to display in my reports.
    But it's not taking correct sql command throwing an error as "SQLcommand not properly ended."
    How can I achieve this?

    You need to use dynamic sql
    But please keep in mind that since you're using Oracle you may be better off posting this in some Oracle forums
    This forum is specifically for SQL Server
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

Maybe you are looking for

  • Standby Database Location not listed

    We have the primary database created and the primary database, server, and agent and the standby server and agent are listed in grid control targets. but when I go to create a new standby database, the standby server is not listed for selection in th

  • Acrobat X Pro help

    Acrobat stops working. I can still generate a PDF which is the funny thing though but I can't open the program itself.

  • Unable to silently install CS3 Design Standard in windows 7

    I have a problem with silently installing CS3 Design Standard in Windows 7. I have done a silent install packages using the instructions in the deployment guide. It works just fine on Windows Vista to deploy using SCCM 2007. But when deploying the sa

  • Unable to install adobe Premiere Pro CC free trial.

    I have Windows 7, I just downloaded the creative cloud. When I pull up my apps to install the Adobe program, it says 'Installation failed' Download error. Anyone know a reason why? Thanks. Bryce~

  • Safari crashes again - can ibod have a looks, thanks

    Here is another safari crash. This is not flip4mac related. Stack trace follows: Host Name: (null) Date/Time: 2005-12-04 22:47:18.477 +0900 OS Version: 10.4.3 (Build 8F46) Report Version: 3 Command: Safari Path: /Applications/Safari.app/Contents/MacO