Any Blog for Scenario Webservice to BAPI/JDBC/*

Hi All:
Can any one send me a blog for webservice to BAPI/JDBC/* scenario. Also how to deploy it in j2ee engine.
I will reward max points for it.
Thanks
Farooq.

How To Develop a Simple Web Service Application Using SAP NetWeaver
Developer Studio & SAP XI 3.0
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/5f3ee9d7-0901-0010-1096-f5b548ac1555

Similar Messages

  • More than one outbound interface for the webservice scenario

    Hi Experts,
    Is it possible to have more than one outbound interface for the Webservice synchronous scenario? I have tried it , but I couldn't implement it.
    I would like to have your suggestions.
    Regards
    Sara

    Hey,
    Creation of a wsdl file
    /people/riyaz.sayyad/blog/2006/05/07/consuming-xi-web-services-using-web-dynpro-150-part-i
    N:1 seemz he was refering to multimapping scenario.
    <b>Cheers,
    *RAJ*
    *REWARD POINTS IF FOUND USEFULL*</b>

  • Any blog avail. as guideline for Designing n arranging UI Elements

    Hi,
        Any Blog available as recommendations to design a page and arranging UI elements and which property of the UI element should used under a scenario.
    Because, some times its difficult to arrange UI elements in a position what we like.
    for example I like to arrange a button UI element at the center of the view, with Matrix layout. I tried few things, but I unable to move it.
    Thank U for Ur time.
    Cheers,
    Sam

    Hi Sam,
        In your case you can try using transparent container. Use transparent container UI element and make it grid layout. Then put your buttons inside transparent container. I have done the same in my project.
       As per my experience we need to do trial and error to get UI elements in place.
    It is difficult initially but once you are used to then you can get it. I tried using groups, transparent container etc. to get UI elements properly.
      You can check out this blog,
      /people/thomas.szcs/blog/2005/12/28/dynamic-programming-in-web-dynpro-abap--introduction-and-part-i-understanding-ui-elements
      https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/media/uuid/bfce2ae7-0b01-0010-829b-effcd2bcbe9d?prtmode=navigate
      Hope my answer will help you.
    Cheers,
    Darshna.

  • Any nice documents on BADIs and BAPIs. why they are used for.

    Any nice documents on BADIs and BAPIs. Because i got a requirement that. any co is using a unified systems. from that i need to integrate with a BW. i have a meeting on next week. i need to prepare for it. any onejust got any documents of this regard is very useful.
    Thanks in advance
    c.s.ramesh
    if u send it to my mail id also it is fine.
    [email protected]

    hi,
    check out the following link
    BAPI.
    http://help.sap.com/saphelp_46c/helpdata/en/9b/417f07ee2211d1ad14080009b0fb56/frameset.htm
    http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci948835,00.html
    Checkout !!
    http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci948835,00.html
    http://techrepublic.com.com/5100-6329-1051160.html#
    http://www.sap-img.com/bapi.htm
    http://www.sap-img.com/abap/bapi-conventions.htm
    http://www.sappoint.com/abap/bapiintro.pdf
    http://www.sapgenie.com/abap/bapi/example.htm
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDAPII/CABFAAPIINTRO.pdf
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/CABFABAPIREF/CABFABAPIPG.pdf
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCFESDE8/BCFESDE8.pdf
    BADI
    http://www.allsaplinks.com/badi.html
    And also download this file....
    http://www.savefile.com/files.php?fid=8913854
    There are other tutorials on this site...
    http://sapbrain.com/Tutorials/tuto_download.html
    BADI'S
    http://help.sap.com/saphelp_erp2005/helpdata/en/73/7e7941601b1d09e10000000a155106/frameset.htm
    http://support.sas.com/rnd/papers/sugi30/SAP.ppt
    http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/abapindx.htm
    http://members.aol.com/_ht_a/skarkada/sap/
    http://www.ct-software.com/reportpool_frame.htm
    http://www.saphelp.com/SAP_Technical.htm
    http://www.kabai.com/abaps/q.htm
    http://www.guidancetech.com/people/holland/sap/abap/
    http://www.planetsap.com/download_abap_programs.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/c8/1975cc43b111d1896f0000e8322d00/content.htm
    /people/thomas.weiss/blog/2006/04/03/how-to-define-a-new-badi-within-the-enhancement-framework--part-3-of-the-series
    /people/thomas.weiss/blog/2006/04/18/how-to-implement-a-badi-and-how-to-use-a-filter--part-4-of-the-series-on-the-new-enhancement-framework
    if helpful provide points
    regards
    harikrishna N

  • Is there any support for JDBC

    Hey All,
    I've started working JDBC since few days and already had early hiccups !!!
    I installed Oracle * into my PC and wrote a simple code to connect to the database unfortunately it didn't connect
    Now I am not sure whether there is any support for JDBC in Oracle 8 or not
    I wonder how can I make sure that my Oracle 8 installed supports JDBC or not
    I use Oracle 8 , jdk1.4, and Winxp as my OS
    Messy

    Oracle supports JDBC at least as far back as 8.1.something; the Oracle JDBC driver is built on a private protocol that existed in at least 8.0, so I'd expect all 8x versions to support JDBC, more or less.
    http://www.oracle.com/technology/tech/java/sqlj_jdbc/htdocs/jdbc_faq.html
    http://www.oracle.com/technology/sample_code/tech/java/sqlj_jdbc/index.html
    http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html
    However, you may want to consider using a newer version of the Oracle database; you can download the latest, and a single-user-for-development-only license is free.
    http://www.oracle.com/technology/software/products/database/oracle10g/index.html

  • Any suggestions for type 4 JDBC drivers for MSSQL

    I am currently using odbc-jdbc bridge for MSSQL 7.0 and I am considerring using a Type 4 driver so that my app can be ported anywhere. Any sugesstion for a FREE type4 JDBC driver for MSSQL 7.0 ??
    I have heard microsoft has released one for MSSQL 2K but I am not sure if it can be used with 7.0.

    you can check that at :
    http://industry.java.sun.com/products/jdbc/drivers

  • Any program for calling bapi from ABAP step by step

    any program for calling bapi from ABAP step by step
    points will be rewarded,
    thank you,
    Jagrut BharatKumar Shukla

    Hi Jagrut,
    BAPI stands for Business API(Application Program Interface).
    A BAPI is remotely enabled function module ie it can be invoked from remote programs like standalone JAVA programs, web interface etc..
    You can make your function module remotely enabled in attributes of Function module but
    A BAPI are standard SAP function modules provided by SAP for remote access. Also they are part of Businees Objest Repository(BOR).
    BAPI are RFC enabled function modules. the difference between RFc and BAPI are business objects. You create business objects and those are then registered in your BOR (Business Object Repository) which can be accessed outside the SAP system by using some other applications (Non-SAP) such as VB or JAVA. in this case u only specify the business object and its method from external system in BAPI there is no direct system call. while RFC are direct system call Some BAPIs provide basic functions and can be used for most SAP business object types. These BAPIs should be implemented the same for all business object types. Standardized BAPIs are easier to use and prevent users having to deal with a number of different BAPIs. Whenever possible, a standardized BAPI must be used in preference to an individual BAPI.
    The following standardized BAPIs are provided:
    Reading instances of SAP business objects
    GetList ( ) With the BAPI GetList you can select a range of object key values, for example, company codes and material numbers.
    The BAPI GetList() is a class method.
    GetDetail() With the BAPI GetDetail() the details of an instance of a business object type are retrieved and returned to the calling program. The instance is identified via its key. The BAPI GetDetail() is an instance method. BAPIs that can create, change or delete instances of a business object type
    The following BAPIs of the same object type have to be programmed so that they can be called several times within one transaction. For example, if, after sales order 1 has been created, a second sales order 2 is created in the same transaction, the second BAPI call must not affect the consistency of the sales order 2. After completing the transaction with a COMMIT WORK, both the orders are saved consistently in the database.
    Create( ) and CreateFromData! ( )
    The BAPIs Create() and CreateFromData() create an instance of an SAP business object type, for example, a purchase order. These BAPIs are class methods.
    Change( )
    The BAPI Change() changes an existing instance of an SAP business object type, for example, a purchase order. The BAPI Change () is an instance method.
    Delete( ) and Undelete( ) The BAPI Delete() deletes an instance of an SAP business object type from the database or sets a deletion flag.
    The BAPI Undelete() removes a deletion flag. These BAPIs are instance methods.
    Cancel ( ) Unlike the BAPI Delete(), the BAPI Cancel() cancels an instance of a business object type. The instance to be cancelled remains in the database and an additional instance is created and this is the one that is actually canceled. The Cancel() BAPI is an instance method.
    Add<subobject> ( ) and Remove<subobject> ( ) The BAPI Add<subobject> adds a subobject to an existing object inst! ance and the BAPI and Remove<subobject> removes a subobject from an object instance. These BAPIs are instance methods.
    ex BAPI:
    API_SALESORDER_CREATEFROMDAT1
    BAPI_SALESORDER_CREATEFROMDAT2
    You can get good help form the following links,
    BAPI-step by step
    http://www.sapgenie.com/abap/bapi/example.htm
    list of all bapis
    http://www.planetsap.com/LIST_ALL_BAPIs.htm
    for BAPI's
    http://www.sappoint.com/abap/bapiintro.pdf
    http://www.sappoint.com/abap/bapiprg.pdf
    http://www.sappoint.com/abap/bapiactx.pdf
    http://www.sappoint.com/abap/bapilst.pdf
    http://www.sappoint.com/abap/bapiexer.pdf
    http://service.sap.com/ale
    http://service.sap.com/bapi
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDAPII/CABFAAPIINTRO.pdf
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/CABFABAPIREF/CABFABAPIPG.pdf
    http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCFESDE8/BCFESDE8.pdf
    http://www.planetsap.com/Bapi_main_page.htm
    http://www.topxml.com/sap/sap_idoc_xml.asp
    http://www.sapdevelopment.co.uk/
    http://www.sapdevelopment.co.uk/java/jco/bapi_jco.pdf
    Also refer to the following links..
    www.sappoint.com/abap/bapiintro.pdf
    www.sap-img.com/bapi.htm
    www.sap-img.com/abap/bapi-conventions.htm
    www.planetsap.com/Bapi_main_page.htm
    www.sapgenie.com/abap/bapi/index.htm
    Checkout !!
    http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci948835,00.html
    http://techrepublic.com.com/5100-6329-1051160.html#
    http://www.sap-img.com/bapi.htm
    http://www.sap-img.com/abap/bapi-conventions.htm
    http://www.sappoint.com/abap/bapiintro.pdf
    http://sap-img.com/bapi.htm
    <b>EG::</b>
    <b>Here is the step by step procedure for creating BAPIs.</b>
    There are 5 different steps in BAPI.
    - Create BAPI Structure
    - Create BAPI Function Module or API Method.
    - Create BAPI object
    - Release BAPI Function Module.
    - Release BAPI object.
    Step1. Creating BAPI Structure:
    - Go to <SE11>.
    - Select Data Type & Enter a name.
    - Click on Create.
    - Note: Always BAPI should be in a development class with request number (Not Local Object).
    - Select Structure & hit ENTER.
    - Enter the fields from your database. Make sure that the first field is the Primary Key Field.
    - Then SAVE & ACTIVATE.
    Step 2. Creating BAPI module:
    - Enter TR.CODE <SE37>.
    - Before entering any thing, from the present screen that you are in, select the menu
    Goto -> Function Groups -> Create Group.
    Enter a name (Note: This name Must start with ZBAPI)
    Let this screen be as it is and open another window and there, enter TR.CODE <SE80).
    Click on the Third ICON that says Inactive Objects.
    Select the group that you just created and click on Activate.
    Notice that the group you created will disappear from the list of inactive objects.
    - Go back to ><SE37> screen and enter a name and hit <ENTER>. Then enter the group name that you just created and activated.
    NOTE: When you release a function module the respective group will be attached to that particular application. It cannot be used for any other application. NEVER include an already existing group that is attached to another module.
    Now click on the first Tab that says [ATTRIBUTES] and select the radio button that says remote-enabled module since we will be accessing this from any external system.
    Then click on the second tab that says [IMPORT].
    Enter a PARAMETER NAME, TYPE and the structure you created in the first step. Also select the check box ‘Pa’. All remotely enabled functional modules MUST be Pa enabled, where Pa means ‘Passed by Value’ and if you don’t select ‘Pa’, then that means it will be passed by reference..
    Then click on tab that says [EXPORT].
    Enter the following as is in the first three fields
    RETURN TYPE BAPIRETURN (These 3 field values are always same)
    Here also select ‘Pa’ meaning Pass by value.
    Note: BAPIRETURN contains structure with message fields.
    Then SAVE and ACTIVATE.
    Step 3. Creating BAPI object:
    - Enter Tr.Code <SWO1> (Note. It is letter ‘O’ and not Zero).
    - Enter a name and then click on create. Enter details.
    NOTE: Make sure that that Object Type and Program name are SAME.
    - Enter Application ‘M’, if you are using standard table Mara. If you are using your own database then select ‘Z’ at the bottom.
    - Then hit <ENTER>.
    - Now we have to add ‘Methods’. High light METHODS and then select the following from the menu:
    Goto Utilities -> API Methods -> Add Methods.
    - Enter function Module name and hit <ENTER>.
    - Select the second FORWARD ARROW button (>)to go to next step.
    - Check if every thing looks ok and again click on FORWARD ARROW button (>).
    - Then select ‘YES’ and click on <SAVE>.
    - Now on a different screen goto TR.CODE <SE37>. Enter Function Module name and select from the top menu Function Module -> Release -> Release.
    - Goback to TR.CODE <SWO1>.
    Here select the menu combination shown below in the same order.
    - Edit -> Change Release Status -> Object Type Component -> To Implemented.
    - Edit -> Change Release Status -> Object Type Component -> To Released.
    - Edit -> Change Release Status -> Object Type -> To Implemented.
    - Edit -> Change Release Status -> Object Type -> To Released.
    - Then click on <SAVE>.
    - Then click on Generate Button (4th button from left hand side looks like spinning wheel).
    - Then Click on the button that says ‘PROGRAM’ to see the source code.
    To check if this is present in work flow goto TR.CODE <BAPI>.
    Here it shows business object repository.
    - First click on the middle button and then select “ALL” and hit ENTER.
    - Goto tab [ALPHABETICAL] and look for the object that you created. This shows that the BAPI object has been created successfully
    <b>Reward pts if found usefull :)</b>
    regards
    Sathish

  • Firefox works on every website except for any blogs. I want to go visit my blogs and to upload, but I keep getting a Problem loading page.

    I can use firefox like normal. It will not allow me to load any blogs. This includes wordpress or blogspot. It worked last week. I do not know what happened.
    == URL of affected sites ==
    http://shastahofer.blogspot.com

    http://kb.mozillazine.org/Error_loading_websites

  • Designing the scenario of multiple BAPI call in a loop in BPM

    All,
    I need some help in designing this scenario. I do not have the luxury to write a custom BAPI. Here is my scenario. A typical async>sync>async with little modification
    1. Async call to BPM with input payload
    2. BPM calla BAPI_SALESORDER_GETLIST with customer number and sales organization from input payload and returns a list sales order items (Sync)
    3. I need to call the BAPI_SALESORDER_GETSTATUS for each sales order number that I got from the first call (Sync?). Not sure how this has to be designed
    4. Transfer the  data through HTTP adapter (Async)
    I am able to perform step 1, 2 and 4 (of course only line item data). I need some pointer help on how to incorporate it in step 3 of BPM.

    3. I need to call the BAPI_SALESORDER_GETSTATUS for each sales order number that I got from the first call (Sync?). Not sure how this has to be designed
    for this the BPM should have a block after the Sync send.......in the block have your send step....the mode of the block will be ForEach....
    Check this blog for more info: /people/milan.thaker/blog/2008/08/05/modes-in-block-step-of-bpm
    Check this similar example from help: http://help.sap.com/saphelp_nw70/helpdata/en/11/13283fd0ca8443e10000000a114084/content.htm
    Edited by: abhishek salvi on Jul 1, 2009 10:57 AM

  • Hi gurus, can any one explain me about Badi & Bapi with eg.?

    Hi gurus,
    Can any one explain me about Badi & Bapi with examples.
    Regards
    Raghu

    Hi Raghu
    1) Badis means:
    The BAdIs of the enhancement concept are not treated as standalone objects, but are integrated in the overall concept. Thus, the tools for defining BAdIs are part of the Enhancement Builder included in the ABAP Workbench.
    Transaction SE18, up to now the only entry point for defining classic BAdIs, now manages classic and new BAdIs. When an existing BAdI is displayed or changed, it analyzes whether the BAdI is a classic or a new one, and then switches to the respective tool. In the case of a new BAdI, this tool is the enhancement spot editor
    2) Bapis means:
    BAPIs can be called within the R/3 System from external application systems and other programs. BAPIs are the communication standard for business applications. BAPI interface technology forms the basis for the following developments:
    Connecting:
    New R/3 components, for example, Advanced Planner and Optimizer (APO) and Business Information Warehouse (BW).
    Non-SAP software
    Legacy systems
    Isolating components within the R/3 System in the context of Business Framework
    Distributed R/3 scenarios with asynchronous connections using Application Link Enabling (ALE)
    Connecting R/3 Systems to the Internet using Internet Application Components (IACs)
    PC programs as frontends to the R/3 System, for example, Visual Basic (Microsoft) or Visual Age for Java (IBM).
    Workflow applications that extend beyond system boundaries
    Customers' and partners' own developments
    Thanks
    Trinath

  • Any Blogs related to Work Flow in PI.

    Hai Experts!
    Any Blogs related to Work Flow in PI.
    Our Requirement is there is need of User Decision.
    Only when the user Approve the Record the Data should get interfaced to the Target System. We are having a Portal Application. So the Approval Screen Should dispaly in Portal. That is When there is any data ready for approval, the user want to get a Task in the Portal.
    Can any one guide me in this scenario. Thanks In Advance.
    Regard's
    Preethi.

    Hi Abu,
      The  basic difference between SAP workflow and PI cc BPM is that SAP WF is limited to steps that operate within SAP ERP system. But with ccBPM you can design a Business Process that runs across multiple systems.
    For example, you can design a business process which involves getting information frm two different systems and combining it to send to a third system using ccBPM.
    Best Regards,
    Ravi

  • With refrence to JohnGoodwing Blog for ODI

    Hi John,
    It is extemely useful blog for many people.
    I stuck with one stage which refer setup connection to a database (ODI Series Part 3 - The configuration continues)
    The next technology to set up is a connection to a database so I can access and write to tables, for me it will be >the Microsoft SQL Server technology but it is very similar for Oracle set up. I have set up a database called HypData. >Once again it is pretty much the same sort of setup but this time you enter the JDBC connection details and yes >you can even hit the test button.Two screenshots which are OK
    As this time we are using a JDBC connection when you set up the physical schema you can don’t have to manually >enter information the drop down boxes are auto populated, the only difference is you have to select the database >name and the owner.I am not sure which Database name and the owner ??? is it related to Hyperion repository or ODI repository?
    I have created two DB odimaster and odiwork. should i need third one hypdata?
    Please help

    I'm sorry to ask again-
    Yes i use csv (source) and Planning (target).
    around 400 rows in csv (formatted for Planning). (which i think small file) 100 KB.
    unless you want to use a database as the staging area, for small data you can easily just use the memory engine.Please guide should i use a DB as staging area?; as i don't require any transformation for this metadata load.
    I have created connection with File, Planning.

  • General questions on IDOCs and IDOCs for 2 Accounting Interface BAPIs

    This post involves several questions pertaining to the topic of IDOC creation. I downloaded a couple of PDFs and tried googling for material on that, but things are far from being clear in my mind.
    I tried to put my questions in some order, so we can follow a line of reasoning. Here we go, then:
    I have one code where I there are calls to 2 BAPIs:
    - BAPI_ACC_ACT_POSTINGS_REVERSE and
    - BAPI_ACC_GL_POSTING_REV_POST
    I am supposed to prepare/create an IDOC to perform the activities these BAPIs are responsible for, for the sole purpose of providing us much more details on the activities being executed in the system - this is one of the IDOC's features, if I got it right, its highly detailed logging of everything that is going on behind.
    Now, the 1st question arises:
    From the material I read, I understood that IDOCs are nothing more than data containers, whose sole purpose is to provide a means of communication between two different systems/parties - one of them would usually be SAP. If this is right, than what sort of IDOC would be this one I am supposed to build - if there's not going to be any inter-system communication ? Doesn't it sound strange that pure "data containers" can work as "logging functions" ? Please share some light here.
    The 2nd question - after I understand what an IDOC really is - is
    then connected to the job I have to do. I found 2 IDOCs which I think have the proper/correspondent basic types for the 2 aforementioned BAPIs. They are, respectively:
    - ACC_DOCUMENT_REVERSE01 and
    - ACC_GL_POSTING_REVERSE01
    Getting back to my understanding of IDOCs, I got that every IDOC is generally made of one control record, data record(s), and status record(s). 3rd question: Where do the segments fit in ? Are the segments definitions of the Data Records ? And why is it that some IDOC types have header segments only and others doesn't have one ? (header segments are not the same as control records, right ?)
    Finally, what is the general process flow for creating/preparing an IDOC ? I looked over a couple of forum posts about this but some of them differ one from another in the order of the steps, some don't mention this or that step, so I am still confused.
    4th and last question: what comes first ? The definition of a partner, the bonding of a message type with an IDOC basic type, definitions of the inbound/outbound interfaces ?
    Any help here would be highly appreciated.
    Thanks in advance,
    Avraham

    Hi Jaya,
    Answer 1. Class is a template for creating objects. Object can also be called as instance.
    Interfaces allow you to use different classes in a uniform way (polymorphism).
    Answer 2. Normal abap is a procedural programming where as by using abap objects we can achieve object oriented programing.
    Answer 6. Source code:
    In below code i have created a interface and a class which is implementing the interface. I have declared a reference variable of type interface and created a object. Then i have called a method.
    REPORT  ZABAPOBJECTS_INTERF.
          INTERFACE I1
    INTERFACE I1.
      METHODS METH1.
    ENDINTERFACE.                    "I1
          CLASS C1 DEFINITION
    CLASS C1 DEFINITION.
      PUBLIC SECTION.
        METHODS: METH2.
        INTERFACES: I1.
    ENDCLASS.                    "C1 DEFINITION
          CLASS C1 IMPLEMENTATION
    CLASS C1 IMPLEMENTATION.
      METHOD I1~METH1.
        WRITE: / 'This is a method one'.
      ENDMETHOD.                                                "I1~METH1
      METHOD METH2.
        WRITE: / 'This is a method two'.
      ENDMETHOD.                                                "METH2
    ENDCLASS.                    "C1 IMPLEMENTATION
    START-OF-SELECTION.
      DATA : REF1 TYPE REF TO I1.
      CREATE OBJECT REF1 TYPE C1.
      CALL METHOD REF1->METH1.
    Question 7: Yes we need to create a class but most probably we use the existing classes.
    Regarding BAPi's go through the below links,
    http://www.sapgenie.com/abap/bapi/example.htm
    http://www.sapdevelopment.co.uk/bapirfc/bapirfchome.htm
    Regards,
    Azaz Ali.

  • Creation of material Documents for RMPM adjustments using BAPI

    Hi
    can any one help me Creation of material Documents for RMPM adjustments using BAPI...
    i should be grateful to you...
    advance thank you
    with regards
    venkat

    You can check MB_CREATE_GOODS_MOVEMENT which has mkpf as inporting parameter.

  • Any room for improvement for this query? Explain Plan attached.

    Is there any room for improvement for this query? Table stats are up-to-date. Any suggestions Query rewrite, addition of indexes,...etc ??
    select sum(CONF
                 when (cd.actl_qty - cd.total_alloc_qty - lsd.Q < 0) then
                  0
                 else
                  cd.actl_qty - cd.total_alloc_qty - lsd.Q
               end)
      from (select sum(reqd_qty) as Q, ITEM_ID as ITEM
              from SHIP_DTL SD
             where exists (select 1
                      from CONF_dtl
                     where CONF_nbr = '1'
                       and ITEM_id = SD.ITEM_id)
             group by ITEM_id) lsd,
           CONF_dtl cd
    where lsd.ITEM = cd.ITEM_id
       and cd.CONF_nbr = '1'Total number of rows in the tables involved
    select count(*) from CONF_DTL;
      COUNT(*)
       1785889
    select count(*) from shp_dtl;
      COUNT(*)
        286675
      Explain Plan
    PLAN_TABLE_OUTPUT
    Plan hash value: 2325658044
    | Id  | Operation                           | Name               | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT                    |                    |     1 |    39 |     4  (25)| 00:00:01 |
    |   1 |  SORT AGGREGATE                     |                    |     1 |    39 |            |          |
    |   2 |   VIEW                              |                    |     1 |    39 |     4  (25)| 00:00:01 |
    |   3 |    HASH GROUP BY                    |                    |     1 |   117 |     4  (25)| 00:00:01 |
    |   4 |     TABLE ACCESS BY INDEX ROWID     | SHIP_DTL           |     1 |    15 |     1   (0)| 00:00:01
    |   5 |      NESTED LOOPS                   |                    |     1 |   117 |     3   (0)| 00:00:01 |
    |   6 |       MERGE JOIN CARTESIAN          |                    |     1 |   102 |     2   (0)| 00:00:01 |
    |   7 |        TABLE ACCESS BY INDEX ROWID  | CONF_DTL           |     1 |    70 |     1   (0)| 00:00:01 |
    |*  8 |         INDEX RANGE SCAN            | PK_CONF_DTL        |     1 |       |     1   (0)| 00:00:01 |
    |   9 |        BUFFER SORT                  |                    |     1 |    32 |     1   (0)| 00:00:01 |
    |  10 |         SORT UNIQUE                 |                    |     1 |    32 |     1   (0)| 00:00:01 |
    |  11 |          TABLE ACCESS BY INDEX ROWID| CONF_DTL           |     1 |    32 |     1   (0)| 00:00:01 |
    |* 12 |           INDEX RANGE SCAN          | PK_CONF_DTL        |     1 |       |     1   (0)| 00:00:01 |
    |* 13 |       INDEX RANGE SCAN              | SHIP_DTL_IND_6 |     1 |       |     1   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       8 - access("CD"."CONF_NBR"='1')
      12 - access("CONF_NBR"='1')
      13 - access("ITEM_ID"="SD"."ITEM_ID")
           filter("ITEM_ID"="CD"."ITEM_ID")

    Citizen_2 wrote:
    Is there any room for improvement for this query? Table stats are up-to-date. Any suggestions Query rewrite, addition of indexes,...etc ??You say that the table stats are up-to-date, but is the following assumption of the optimizer correct:
    select count(*)
    from CONF_dtl
    where CONF_nbr = '1';Does this query return a count of 1? I doubt that, but that's what Oracle estimates in the EXPLAIN PLAN output. Based on that assumption you get a cartesian join between the two CONF_DTL table instances, and the result - which is still expected to be one row at most - is then joined to the SHIP_DTL table using a NESTED LOOP.
    If above assumption is incorrect, the number of rows generated by the cartesian join can be tremendous rendering the NESTED LOOP operation quite inefficient.
    You can verify this by using the DBMS_XPLAN.DISPLAY_CURSOR function together with the GATHER_PLAN_STATISTICS hint, if you're already on 10g or later.
    For more information regarding the DISPLAY_CURSOR function, see e.g. here: http://jonathanlewis.wordpress.com/2006/11/09/dbms_xplan-in-10g/
    It will show you the actual cardinalities compared to the estimated cardinalities.
    If the estimate of the optimizer is incorrect, you should find out why. There still might be some issues with the statistics, since this is most obvious reason for incorrect estimates.
    Are your index statistics up-to-date?
    Regards,
    Randolf
    Oracle related stuff blog:
    http://oracle-randolf.blogspot.com/
    SQLTools++ for Oracle (Open source Oracle GUI for Windows):
    http://www.sqltools-plusplus.org:7676/
    http://sourceforge.net/projects/sqlt-pp/

Maybe you are looking for