How to use index in a view?

Hi!
I have a view created of the following structure:
create or replace view v as
  select col1, col2
  from a
union all
  select col1, col2
  from bwhere both tables a and b have indexes on col1 - named i1 and i2 respectively.
While using the view v I want to ensure that I use the indices defined to access data. How can I achieve that by means of optimizer hints? (or by means of anything else).
Any feedback is appreciated. Thanks.

Okay, here's what I have to deal with:
For some reasons (out of my control) I have to use an Oracle Report*Writer 1.0 to present data from Oracle 9i DB.
My simple (one query) report is running too slowly. It takes unlimited time to complete (at least more than 1,5 hour). But when I pull out the SQL query executed by the Report*Writer's session (using the tool 'PL/SQL Developer') and rerun it in the Developer it works just in 10sec. And I wonder why?
At the moment I want to somehow manipulate execution plan (without using outlines and in fact without appropriate tools as have no access to OS (i.e. to take actual trace files from there))
That's why I ask if I can somehow make sure that the Server uses indices while processing the query.

Similar Messages

  • Regarding how to use index , please give me some example if possible

    Hello everybody:
           Thank you all for your help in  advance .
           would you please tell me how to use index, please give me  some example if possible.  couldn't thank you more!
          best regards .
         Frank

    Index is used for faster access of data base tables.
    An index helps to speed up selection from the database. An index is a sorted copy of selected database table fields.
    The primary index is always automatically created in an ABAP-based SAP system. It consists of the primary key fields of the database table. This means, for each combination of the index fields exists a maximum of one record in the table. This kind of index is called a UNIQUE index.
    If the primary index cannot be used to determine selection result, (for example, the WHERE condition does not contain any primary index fields), the system searches the whole table. To prevent this, and determine the selection result by searching through a restricted number of database records, you can create a secondary index.
    However, you should not define an index for all possible fields in the WHERE condition.
    Check this thread..u have more details.
    In which situation we can use the reading of  index

  • How to use layout of one view(some part) in another view

    Hi All,
                 I need how to use a layout of one view(some part) in another view.if anybody knows, help me.
    Ex : I took two views.but some part of layout in first view is also needed in second view.Is it possible.
    Thank You,
    Anupama.

    Hi,
    Whichever common ui elements you want to put in both views. Keep them in one view.
    Now create two views which You want to display.( i.e you have to create three views in that two only will be used for display purpose ) In that both views add viewcontainer ui element and embedd that view which has common UIs. And Then add rest uncommon UIs in both views.
    I hope it helps.
    Regards,
    Rohit

  • How to use Index, Match, or lookup for multi cell data..

    Hey all,  I'm new to using numbers (any spreadsheet really).  I can't figure out how to make this work.
    What I want to do for example is lookup a weight value in (F) by matching all the criteria in (A),(B),(C),(D) & (E).  If possible I would like my search criteria to match everything exactly except the Temp in (E).  The search temp can be warmer or greater than the temp listed. 
    I've tried using Index and Match together but I can't figure out how to match more than one valvue.  If all the other criteria is matched there should only be one weight to return.  I can match one criteria valvue but it only returns the first or last match.  I need it to match each item and return one weight.  What am I doing wrong??
    Please help, and keep it simple for the stupid me.
    Thanks

    The difficulty here is that MATCH and VLOOKUP return the values from the single row with the first match best fitting the type of match specified. VLOOKUP searches from the bottom of the column, MATCH form the top.
    I'd suggest a rearrangement of your data to allow a search with fewer steps.
    Since you want an exact match for the first four columns and a 'smallest value equal to or greater than' match for the fifth column I would suggest concatenating the values in columns A through E into a single value in a new column F inserted after column E.
    For the part of the data table shown, this concatenated value would remain the same for 13 rows, while the temperature ranges in five degree steps from -20 to +45, then a single three-degree step to 48.
    One value in those concatenated then changes, and the new concatenated value repeats for the next 13 rows with the temperature passing through the same range with the same steps.
    If this pattern is consistent (or even reasonably consistent) through the whole table. then a rearrangement of the data as shown below will greatly reduce table size and search time.
    Each distinct set of values A though D is presented on only a single row, the four values are concatenated in column E, and are followed by the temperature values, one per column, in the header row, with the associated weights for those conditions and that temperature listed across that row.
    Note: weights in row 2 (runway 13) are taken from your table. Boredom with retyping then set in, so those in row 2 (runway 31) are formula generated to present a series of decreasing weights, but bear no other relation to those in your table.
    With the table presented in this form, the search is reduced to a single OFFSET expression, with the ROW offset determined by matching the concatenated value of columns A-D of the Query table with their exact counterpart in the Data table, and the column offset determined by matching the temperature in the Query with its closest less than or equal to match in row 1 of Data.
    Formula:
    Query::F2: =OFFSET(Data :: $A$1,MATCH(A&B&C&D,Data :: $E,0)-1,MATCH(E,Data :: $1:$1,1)-1)
    Not handled: What do you want returned for temperatures less than -20 or greater than +48 degrees? As written, the formula will return a not found error for -21 and below, and the value associated with 48° for 49 and above.
    Regards,
    Barry

  • How to use Parameter in inline view

    I want to deploye following sql in discoveror. Problem is that how to use the P_TO_DATE in disco.
    select papf.employee_number, papf.effective_start_date, papf.effective_end_date, paaf.effective_start_date, paaf.effective_end_date,
    (select peev.screen_entry_value
    from pay_element_types_f pet,
    pay_element_classifications pec,
    pay_input_values_f piv,
    pay_element_entries_f pee,
    pay_element_entry_values_f peev
    where pet.classification_id = pec.classification_id
    and pet.processing_type = 'R'
    and pec.classification_name = 'Earnings'
    and piv.name in ('Monthly Amount')
    and pet.ELEMENT_TYPE_ID = piv.ELEMENT_TYPE_ID
    and pet.element_type_id = pee.element_type_id
    and piv.INPUT_VALUE_ID = peev.INPUT_VALUE_ID
    and pet.ELEMENT_NAME = 'Basic Salary'
    and pee.ELEMENT_ENTRY_ID = peev.ELEMENT_ENTRY_ID
    and pee.assignment_id = paaf.assignment_id
    and pee.effective_start_date <= :P_TO_DATE and pee.effective_end_date >= :P_TO_DATE
    and peev.effective_start_date <= :P_TO_DATE and peev.effective_end_date >= :P_TO_DATE ) Basic_Salary
    from per_assignments_f paaf, per_people_f papf
    where papf.person_id = paaf.person_id
    and papf.employee_number = '101111'

    Hi,
    What you can do is to change the query so that the parameters will be in the where clause and then you can define the condition with the parameter in the dicoverer worksheet.
    Use the following code instead of your own:
    select papf.employee_number,
    papf.effective_start_date,
    papf.effective_end_date,
    paaf.effective_start_date,
    paaf.effective_end_date,
    Basic_Salary.p_start_date1, ---> create the conditions on those fields
    Basic_Salary.p_start_date2,
    Basic_Salary.p_end_date1,
    Basic_Salary.p_end_date2
    from per_assignments_f paaf,
    per_people_f papf,
    (select peev.screen_entry_value,
    pee.assignment_id,
    pee.effective_start_date p_start_date1, --parameter
    pee.effective_end_date p_end_date1, --parameter
    peev.effective_start_date p_start_date2,--parameter
    peev.effective_end_date p_end_date2
    from pay_element_types_f pet,
    pay_element_classifications pec,
    pay_input_values_f piv,
    pay_element_entries_f pee,
    pay_element_entry_values_f peev
    where pet.classification_id = pec.classification_id
    and pet.processing_type = 'R'
    and pec.classification_name = 'Earnings'
    and piv.name in ('Monthly Amount')
    and pet.ELEMENT_TYPE_ID = piv.ELEMENT_TYPE_ID
    and pet.element_type_id = pee.element_type_id
    and piv.INPUT_VALUE_ID = peev.INPUT_VALUE_ID
    and pet.ELEMENT_NAME = 'Basic Salary'
    and pee.ELEMENT_ENTRY_ID = peev.ELEMENT_ENTRY_ID
    ) Basic_Salary
    where papf.person_id = paaf.person_id
    and Basic_Salary.assignment_id = paaf.assignment_id
    --and Basic_Salary.p_start_date1 <= :P_TO_DATE
    --and Basic_Salary.p_start_date2 <= :P_TO_DATE
    --and Basic_Salary.p_end_date1 >= :P_TO_DATE
    --and Basic_Salary.p_end_date2 >= :P_TO_DATE
    --and papf.employee_number = '101111'                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How to use index, when query has decode/case

    Hi,
    I have the following query
    i have a index on party_id,party_type_Code in the zx_party_tax_profile table But this index is not used as Iam using a decode on the columns of the zx_party_tax_profile table,
    Is there any way i can rewrite the query so that it uses index
    sELECT /*+ INDEX(ZX_PARTY_TAX_PROFILE_U2) */ party_tax_profile_id FROM (SELECT
    ThirdPartyTaxProfileEO.SUPPLIER_FLAG,
    ThirdPartyTaxProfileEO.CUSTOMER_FLAG,
    ThirdPartyTaxProfileEO.SITE_FLAG,
    ThirdPartyTaxProfileEO.PARTY_TAX_PROFILE_ID,
    ThirdPartyTaxProfileEO.PARTY_ID,
    ThirdPartyTaxProfileEO.REP_REGISTRATION_NUMBER,
    ThirdPartyTaxProfileEO.OBJECT_VERSION_NUMBER,
    ThirdPartyTaxProfileEO.REGISTRATION_TYPE_CODE,
    ThirdPartyTaxProfileEO.COUNTRY_CODE,
    ThirdPartyTaxProfileEO.MERGED_TO_PTP_ID,
    ThirdPartyTaxProfileEO.MERGED_STATUS_CODE,
    ThirdPartyTaxProfileEO.PROGRAM_APP_NAME,
    ThirdPartyTaxProfileEO.PROGRAM_NAME,
    PartyPEO.PARTY_NAME,
    PartyPEO.PARTY_ID AS PARTY_ID1,
    PartyPEO.PARTY_NUMBER,
    decode(ThirdPartyTaxProfileEO.CUSTOMER_FLAG,
    'Y',decode(ThirdPartyTaxProfileEO.SUPPLIER_FLAG,
    'Y', 'SC',
    'C'),
    decode(ThirdPartyTaxProfileEO.SUPPLIER_FLAG,
    'Y', 'S',
    NULL)
    ) AS PARTY_USAGE,
    ThirdPartyTaxProfileEO.REP_REGISTRATION_NUMBER AS TAX_REG_NUMBER,
    LkupPartyUsage.MEANING AS PARTY_USAGE_DESC,
    PartyPEO.PARTY_NAME AS PARTY_FULL_NAME,
    PartyPEO.ADDRESS1||','||
    PartyPEO.ADDRESS2||','||
    PartyPEO.ADDRESS3||','||
    PartyPEO.CITY||','||
    PartyPEO.postal_code||','||
    PartyPEO.COUNTRY AS ADDRESS,
    PartyPEO.COUNTRY AS COUNTRY_CODE_TCA,
    TerritoryPEO.TERRITORY_SHORT_NAME AS COUNTRY_NAME,
    PartyPEO.JGZZ_FISCAL_CODE AS TAX_PAYER_ID,
    PartyPEO.DUNS_NUMBER_C AS DUNS_NUMBER,
    PartyPEO.Party_Number as Party_Num_Calc,
    null as REGISTRATION_TYPE_NAME,
    null as ROUNDING_LEVEL_NAME,
    null as ROUNDING_RULE_NAME,
    null as COUNTRY_NAME_PTP,
    'ZX_PARTY_TAX_PROFILE' as TAX_REPORTING_ENTITY_CODE
    FROM ZX_PARTY_TAX_PROFILE ThirdPartyTaxProfileEO,
    HZ_PARTIES PartyPEO,
    FND_LOOKUP_VALUES_VL LkupPartyUsage,
    FND_TERRITORIES_VL TerritoryPEO
    WHERE ThirdPartyTaxProfileEO.PARTY_ID = PartyPEO.PARTY_ID AND
    LkupPartyUsage.LOOKUP_CODE = decode(ThirdPartyTaxProfileEO.CUSTOMER_FLAG,
    'Y',decode(ThirdPartyTaxProfileEO.SUPPLIER_FLAG,
    'Y', 'SC',
    'C'),
    decode(ThirdPartyTaxProfileEO.SUPPLIER_FLAG,
    'Y', 'S',
    NULL)
    ) AND
    PartyPEO.COUNTRY = TerritoryPEO.Territory_Code (+) AND
    LkupPartyUsage.LOOKUP_TYPE = 'ZX_TP_PARTY_USAGE'
    ORDER BY UPPER(PARTY_FULL_NAME)) QRSLT WHERE UPPER(PARTY_NAME) IS NOT
    NULL
    Any help will be appreciated

    You can rewrite your where clause to not use decode or case statements e.g. this:
      AND LkupPartyUsage.LOOKUP_CODE = DECODE( ThirdPartyTaxProfileEO.CUSTOMER_FLAG
                                , 'Y', DECODE( ThirdPartyTaxProfileEO.SUPPLIER_FLAG, 'Y', 'SC', 'C' )
                                     , DECODE( ThirdPartyTaxProfileEO.SUPPLIER_FLAG, 'Y', 'S', NULL ) )
                                     )can be rewritten to this:
    and (
          ( ThirdPartyTaxProfileEO.CUSTOMER_FLAG = 'Y'  AND
              ((ThirdPartyTaxProfileEO.SUPPLIER_FLAG = 'Y' AND LkupPartyUsage.LOOKUP_CODE = 'SC') or
                ThirdPartyTaxProfileEO.SUPPLIER_FLAG != 'Y' AND LkupPartyUsage.LOOKUP_CODE = 'C')) or
          ( ThirdPartyTaxProfileEO.CUSTOMER_FLAG != 'Y'  AND
              ((ThirdPartyTaxProfileEO.SUPPLIER_FLAG = 'Y' AND LkupPartyUsage.LOOKUP_CODE = 'S') or
                ThirdPartyTaxProfileEO.SUPPLIER_FLAG != 'Y' AND LkupPartyUsage.LOOKUP_CODE is null))
        )It's not as sussinct, but it avoids the use of functions that could be preventing the optimiser from using an index.

  • How to use index when use analytic functions?

    Oracle 11gR2, I have a an indexed snapshot log table (sequence$$ and PK indexed), and I use a query to access it...
    query looks like:
    SELECT "M_ROW$$", "SNAPTIME$$", "DMLTYPE$$", "OLD_NEW$$", "CHANGE_VECTOR$$", "SEQUENCE$$", "ID", "SITEID", "WEBPAGEID", "WEBFOLDERID"
    FROM mlog$_table1
    WHERE dmltype$$ = 'D'
    AND sequence$$ IN
    (SELECT DISTINCT
    LAST_VALUE (sequence$$)
    OVER (PARTITION BY siteid ORDER BY siteid)
    FROM mlog$_table1);
    how could I access mlog$_table1
    explain plan looks like:
    Plan
    SELECT STATEMENT ALL_ROWSCost: 53 Bytes: 605.864 Cardinality: 1.736                          
         6 HASH JOIN Cost: 53 Bytes: 605.864 Cardinality: 1.736                     
              4 VIEW VIEW SYS.VW_NSO_1 Cost: 28 Bytes: 22.555 Cardinality: 1.735                
                   3 HASH UNIQUE Cost: 28 Bytes: 45.110 Cardinality: 1.735           
                        2 WINDOW SORT Cost: 28 Bytes: 45.110 Cardinality: 1.735      
                             1 TABLE ACCESS FULL TABLE BONGO.MLOG$_PDSI1 Cost: 25 Bytes: 45.110 Cardinality: 1.735
              5 TABLE ACCESS FULL TABLE BONGO.MLOG$_PDSI1 Cost: 25 Bytes: 582.960 Cardinality: 1.735

    ok, I think I feel like a newbie :)
    explain plan for your query is:
    Plan
    SELECT STATEMENT ALL_ROWSCost: 22,1 Bytes: 416,678 Cardinality: 2,654           
         2 SORT GROUP BY Cost: 22,1 Bytes: 416,678 Cardinality: 2,654      
              1 TABLE ACCESS FULL TABLE IBIS.MLOG$_PARTIJA Cost: 22,098 Bytes: 416,678 Cardinality: 2,654
    but it runs for about 3-4 sec..
    1st query:
    create or replace view x as
    select * from mlog$_partija v
    where not (DMLTYPE$$='D' and update_type=2)
    and sequence$$=(select max(sequence$$) from mlog$_partija t
    where t.par_sifpar=v.par_sifpar);
    runs about 17 sec...
    wich is expected since there's a max in subselect...
    but, it's explain plan is:
    Plan
    SELECT STATEMENT ALL_ROWSCost: 108,957 Bytes: 1,84 Cardinality: 1                     
         5 HASH JOIN Cost: 108,957 Bytes: 1,84 Cardinality: 1                
              3 VIEW VIEW SYS.VW_SQ_1 Cost: 22,564 Bytes: 68.634.228 Cardinality: 2.639.778           
                   2 HASH GROUP BY Cost: 22,564 Bytes: 68.634.228 Cardinality: 2.639.778      
                        1 TABLE ACCESS FULL TABLE IBIS.MLOG$_PARTIJA Cost: 22,05 Bytes: 68.634.228 Cardinality: 2.639.778
              4 TABLE ACCESS FULL TABLE IBIS.MLOG$_PARTIJA Cost: 22,145 Bytes: 4.788.557.292 Cardinality: 2.639.778           
    but, I made a third solution wich is something like:
    create table mlog_table1_last as
    select siteid, max(sequence$$) max_seq from mlog$_table1 group by siteid
    I run a query on that temp table:
    select * from mlog$_table1 v
    where not (DMLTYPE$$='D' and update_type=2)
    and sequence$$=(select max_seq from mlog_table1_last t
    where t.siteid=v.siteid);
    it's explain plan is bad:
    Plan
    SELECT STATEMENT ALL_ROWSCost: 2.588.886 Bytes: 1,814 Cardinality: 1           
         3 FILTER      
              1 TABLE ACCESS FULL TABLE IBIS.MLOG$_PARTIJA Cost: 22,148 Bytes: 4.788.557.292 Cardinality: 2.639.778
              2 INDEX RANGE SCAN INDEX IBIS.MLOG_PARIJA_LAST_NDX2 Cost: 1 Bytes: 111,02 Cardinality: 4,27
    but it runs for 1-2 sec..
    why?

  • How to use one DC's view/component/appln in another DC

    Hi All,
      I am new to DC concept. I am trying to use one DC's component in another DC. I have done following steps.
    a)Created two DCs A and B
    b) DC A's 'New Public Part-->Entity Type(Web Dynnpro Component) I selected component
    c) Add Used DC in B, I added A's component
    <b> From this point onwards I am not getting any clues</b>. How do I call A's component in DC B. <i>Please guide. Any examples will be great.</i>
    Thanks and Regards,
    Ganga.

    Hi Gangadharaya,
    Just tell me do u want to display a view, use some context or use some methods defined in other controller.
    So that i can help you in the same direction.
    <b>Component Usage</b>
    Suppose you have following scenario:
    1) DC2 has component Comp2. In this dc you read the context a value and stores it in context named "Ctx_value".
    2) DC1 has component Comp1. Here you want to read the Ctx_value from comp2.
    In Comp2 create a method getValue()
      public java.lang.String getProcessId( )
          return wdContext.getCurrentElement().getAttributeValue("Ctx_value");
    In the interface controller of Comp2 click on properties tab and add reference to the cont2 controller. Now create a method here in interface controller to get the value of Ctx_value
      public java.lang.String getValue( )
        return wdThis.wdGetComp2Controller().getValue();
    Expose the Comp2 as public part now.
    In DC1 add DC1 as used DC.
    Build both dc's
    In Comp1 create Component usage by name Comp2Usage to Comp2.
    Now you can access the method getValue() from interface controller of Comp2.
    wdThis.wdGetComp2UsageInterface().getValue();
    This is how you can access a value of Context. Same can be done by direct binding.
    <b>View Access</b>
    If you want to access a view v2 in comp2 then goto windows in comp1 and embedd an existing view and in that select the interface view of comp2. The default view in comp2 can now be displayed in comp1.
    Regards,
    Murtuza
    Message was edited by:
            Murtuza Kharodawala

  • How to use Device Profiles and Viewing Conditions Profile in Photoshop Elements 11?

    In trying to get to grips with the Colour management aspects of PSE11, I have encountered the following problems:
    Having selected "Display" a sequence of clicks (Change display settings -> Advanced settings -> Colour Management -> Colour Management tab -> Colour Management)
    gives a screen which includes the headings:
    Device Profile  and Viewing Conditions Profile.
    1. Device Profile. Besides sRGB and ARGB, the profile list includes the profiles for all of the Epson papers. (I have an Epson Stylus Photo PX810FW).
    I changed the Profile to an Epson Grayscale, this was accepted within the menu, but there are no changes from normal when I viewed the image on the Windows screen or within
    PSE11. ("normal" is sRGB or ARGB).
    I thought it worth a try to test that, if I wanted the display image to closely represent what I would get on a particular Epson paper, this may be a way to do it.(I suspected this approach because I have never
    seen it in the literature!).
    So what is the purpose of all of the paper Profiles appearing in the Display listing?
    2. The Viewing Conditions Profile has also several options. I have tried to find the criteria for choosing one rather than the other, but failed to find any information. Can anyone help? I seek general guidance
    rather than the details of the Profiles.
    As a seperate question:
    Selecting Image on the PSE11 menu across the top of the displayed image, and then Convert Colour Profile, I tried this process on an image, converting tiff to sRGB. When saved there was an extra asterisk in the saved title but in this case,
    the file was still labelled tiff and there was no change in the number of Mbs. If a conversion has taken place, how is one to know?  Does saving a tiff file as jpeg change its colour profile? When is it useful to use this feature?
    Many thanks to all responders! 

    Addressing your second question, you are confusing two different things.
    tiff is an image file format, as is jpeg, as is psd, as is png, as are dozens (if not hundreds, http://en.wikipedia.org/wiki/Image_file_formats) of other formats.
    A colour profile represents the colour characteristics of devices so that, for example, displays know how to display the colours, printers know how to print them.
    Image files MAY, but do not have to, contain colour profiles.
    For details:
    http://help.adobe.com/en_US/creativesuite/cs/using/WS52323996-D045-437d-BD45-04955E987DFB. html
    http://en.wikipedia.org/wiki/Color_management#Color_profiles
    http://en.wikipedia.org/wiki/ICC_profile
    Cheers,
    Neale
    Insanity is hereditary, you get it from your children
    If this post or another user's post resolves the original issue, please mark the posts as correct and/or helpful accordingly. This helps other users with similar trouble get answers to their questions quicker. Thanks.

  • How to use WDR_SELECT_OPTIONS in a view without using window embeding

    Hey guys,
    I want to use Select Options (via Comp. WDR_SELECT_OPTIONS ) in a Web Dynpro View - V_SUB. This subview is already embedded in a main view V_MAIN dynamically at runtime. Now it is not possible for me to implement the select option usage in V_SUB correctly because I don't have the window information for embedding at design time.
    Do you know how this problem can be solved? I already tried the window runtime interface: if_wd_rr_window->embed_view like this:
      lr_window_rr->embed_view( used_view_name     = 'WND_SELECTION_SCREEN'
                                used_component_name = 'WDR_SELECT_OPTIONS'
                                COMPONENT_USAGE_NAME = 'USE_SELECT_OPTIONS'
                                embedding_position = 'V_SUB/VC_SELOPT' ).
    "USE_SELECT_OPTIONS" is my usage name for the wd comp. wdr_select_options
    However this didn't work
    Thanks for any advice...
    Regards
    Sebastian

    can be done with prepare_dynamic_navigation( )

  • How to use data from standard view in Web dynpro for ABAP

    Hello:
    I have to create an Abap Web Dynpro, and I must use data from a standard view in the new one. Does anybody know what do I have to do?
    Thank you and have a happy new year.

    Hi Rodrigo,
    Firstly, list the Standard component under Component Usage of the Component which you are creating in your View.
    Second, In the Custom Component, view, goto context, and try to add the node from the Standard component in to your view.
    NOTE: The second step requires a Node in component controller of the Standard Component.
    Finally, Now in your view, get the data from that and map the data.
    NOTE: To do this, I think you need to call your Standard WDA first and then only your node contains data and it will be passed.
    I hope it is helpful.
    Regards,
    Shashikanth. D

  • How to use indexes correctly in oracle

    Hi guys
    on one table i have indexes on 3 columns in the following order
    a
    b
    c
    When i m writing a select statement in my where clause what should be the order? like
    where
    a='some value' and
    b='some value' and
    c='some value';
    or in reverse order like this
    c='some value' and
    b='some value' and
    a='some value';
    please let me know.
    Thanks

    If you have an index on a,b,c the difference in performance can be on the index order.
    If column "a" has only 2 unique values then the sub values of the index only has 50% of the remaining values, the cost optimizer on Oracle will probably skip the index as an index scan of 50% is slower than a full table scan.
    If a has 100 unique values then the remaining search is only on 1% of the values so is likely to be used.
    As with any optimisation try using
    explain plan for selec x,y,z from a_table
    from where
    a='some value' and
    b='some value' and
    c='some value'
    If the index is not being used firstly try
    analyze table estimate statistics
    sample 10 percent
    for all indexes
    for all indexed columns;
    and failing than try different orders in acceptance environment.

  • How to use BETWEEN operator in View Criteria

    Hello Champs,
    I want to query some data based on date range Value for e.g From "21-JUN-06 " TO "21-JUL-06"
    How can I do this using the ViewCriteria
    ViewCriteria vc = vo.createViewCriteria();
    ViewCriteriaRow vcRow = vc.createViewCriteriaRow();
    vcRow.setAttribute(attrName," BETWEEN " + "'" + fromDateValue + "'" + " AND '" + ToDateValue + "'");
    vc.addElement(vcRow);
    vo.applyViewCriteria(vc);
    vo.executeQuery();
    does not seems to work, no errors either
    thank you all in advance

    Thanks, Timo,
    I was passing invalid date format
    it was looking for yyyy-mm-dd
    and passed value was 2006/05/05 so, / does matter;
    select * from EMP WHERE TO_CHAR(EMP_JOIN_DATE,'yyyy-mm-dd') BETWEEN '2006-05-05' AND '2006-06-30'; will work
    select * from EMP WHERE TO_CHAR(EMP_JOIN_DATE,'yyyy-mm-dd') BETWEEN '2006/05/05' AND '2006/06/30'; will not work

  • How to Use Sequence in Oracle Views

    Hi ,
    I have created a view which gives the information about the access rights which a Resource has got. for ex -
    Res1 - GYM access - member
    Res1 - Swimingpool Access - member
    I need to identify a Primary Key for this data set. So i thought that i'll use a Sequence to generate an extra column in this view.
    But when i'm using the Sequence i'm getting the following error - "ORA-02287".

    you can use sequence within view it doesnot returned error;
    create sequence t1_seq MAXVALUE 150
    START WITH 39 INCREMENT BY 1;
    SQL> insert into t1_view values(t1_seq.nextval,'dd');
    1 row created.
    SQL> commit;
    Commit complete.
    SQL> select * from t1;
    ID NA
    10 aa
    20 bb
    30 cc
    40 dd
    4 rows selected.
    SQL> insert into t1_view values(t1_seq.nextval,'ee');
    1 row created.
    SQL> commit;
    Commit complete.
    SQL> select * from t1;
    ID NA
    10 aa
    20 bb
    30 cc
    40 dd
    41 ee
    5 rows selected.

  • How to use index of Oracle Table in EJB??

    Hello I have a Table Department and it's index on Dpt_Name column.
    I have created ejb - cmp in OC4J for Department Table.
    I am getting all the data but it is not in index on department, Where I have to specify index of table in Oc4j.
    Reply appriciated.
    Rajiv

    Rajive,
    An index is used automatically by the Database for faster retrieval of data. The query optimizer in the database determines whether to use an index and which index to use for a SQL statement and you don't have to specify the index in OC4J.
    If you have an index on deptname, then the index will be used when the SQL has a where clause like "where deptname = 'Personal' " or
    "where deptname like 'P%' ", etc. In case of CMP, if you have a finder method called findByDeptName and then this index will be used.
    For details on deciding on your indexing strategies please look at http://otn.oracle.com/docs/products/oracle9i/doc_library/release2/appdev.920/a96590/adg06idx.htm#11977
    regards
    Debu Panda
    oracle

Maybe you are looking for

  • How can I get a spyder2pro to work with Lion? Color vision says that Rosetta isn't compatible with Lion.

    How can I get updated software so my spyder2pro works on my MacBook Pro?

  • Sales Order Changes within Last 5 Days

    Hi Guys, Has anyone done a query that shows changes made to a sales order within the last 5 days, for example if lines have been added or deleted, items changed, quantity changed or delivery date changed. I suspect I need to bring in all the history

  • Email Activity dispatch exception

    I am trying to send email in a BPEL process, I am getting the following exception (in simple bpel process the email activity is working fine) <2008-08-12 13:12:10,137> <ERROR> <default.collaxa.cube.engine.dispatch> <BaseScheduledWorker::process> Fail

  • Powershell SMO SQL Server Mirror Databases

    Hello, I am almost done writing a script to help my team manage mirrored database during planned outages.  I would like to do determine the role of the database (principal or mirror). If I query atheDMV sys.database_mirroring, I am able to determine

  • Fullscreen across 3 monitor

    hi am pretty desperate... is there a way to open a projector i created (maximum 2800x768 in flash) which is as-ed to open fullscreen across 3 monitors, hitting a resolution of 3072x768?