Master detail relation in the sql report

HI All
I am using Oracle 10g and have a requirement where I need to generate the output in the following format
Deptno 10
Empno Ename
1 ----------A
2 ----------B
Deptno 20
Empno Ename
3-----------C
4-----------D
5-----------E
Deptno 30
Empno Ename
6-----------F
7-----------G
Can we do it throgh sql report in sqlplus.
Thanks
Edited by: user602329 on Sep 15, 2010 10:18 PM

Hi,
In pure SQL, you can get results like that using GROUP BY ROLLUP, and also using UNION. In this case, I suspect UNION would be a lot simpler.
Using SQL*Plus fucntionality, you could also write a SQL-from-SQL script that writes (and runs) a separate query for each department, the output of which is exactly what you requested.
I'd try UNION first.
Write one query to get the rows like
Deptno 10from your table, using GROUP BY deptno.
Write another query to get the rows like:
Empno Enamefrom your table, using GROUP BY deptno to get one such row per department. (It's possible to combine these two queries, but simpler not to.)
Write another query to get the actual data, such as
EMPNO  ENAME
=====  =====
1      A
2      B
3      C
4      D
5      E
6      F
7      GThen do a UNION of all three queries, with an ORDER BY clause to get them in the right order.
Each branch of the UNION will need some extra columns, to make the sorting work right. That is, the result set of the UNION will look something like this:
OUT1   OUT2        EMPNO     DEPTNO     QUERYNO
Deptno 10               10     1          
Deptno 20                   20     1
Deptno 30                   30     1
EMPNO  ENAME               10     2
EMPNO  ENAME               10     2
EMPNO  ENAME               10     2
1      A        1          10     3
2      B        2          10     3
3      C        3          10     3
4      D        4          10     3
5      E        5          10     3
6      F        6          10     3
7      G        7          10     3If you're going to have text, like 'EMPNO' in the 1st column, but empno is a NUMBER, then you should convert the NUMBERs to VARCAHR2s, using TO_CHAR.
You probably won't want to display those extra columns, so use the SQL*Plus "COLUMN ... NOPRINT" command to hide them, or do the UNION in a sub-query, and then do the ORDER BY in a super-query, where you can use columns in the ORDER BY clause without putting them in the SELECT clause alsio.
Edited by: Frank Kulash on Sep 16, 2010 11:02 AM

Similar Messages

  • Master detail relation in the ADF Jdev10g sample application

    Hi,
    I have to develop Master detail relation in the ADF Jdev10g. Need sample application...Can anybody help me..

    Lots and lots of tutorials [url http://www.oracle.com/technetwork/developer-tools/jdev/overview/index-100269.html]here
    Note: 11g has been out for some time now, and if you are doing new development, it really makes sense to be using the latest software. If, by chance, you happen to be talking about doing development for the E-Business Suite, you want to be asking on the OA Framework forum.
    John

  • Need Master-Detail relation to link Master column to 2 different detail col

    I have a form with a master detail relation. The master block is a database table rec_shipments with a primary key of shipment_id and a bunch of other columns. The detail block is a table rec_containers with a container_id as the primary key plus column shipment_id, split_shipment_id, weight, volume, etc. The shipment_id and split_shipment_id are nullable.
    When a shipment is received a shipment record is created and container records are created with the shipment_id populated and the split_shipment_id null. In the form a relation was created between the shipment block and the container block as shipment_id=shipment_id. This works fine. However, they have the ability to spit the original containers into smaller more manageable containers for distribution. For example if they receive a railroad car full of pallets of printer paper they may take and divide them, half into 1 rolloff bin and half into another rolloff bin. The rolloff bins will get a unique container_id for tracking. The record in the system created in the rec_containers table will have the split_shipment_id populated and the shipment_id null. In the screen they want to see the original containers (railroad car) and the split containers (rolloff bins) when the query the shipment.
    What they want:
    Shipment_id -- and additional information
    Railroad Car ID plus additional information
    Rolloff Bin 1 ID plus additional information
    Rolloff Bin 2 ID plus additional information
    My problem is the rolloff bins don't show up with the current relation because the shipment_id is null in the 2 rolloff bin records.
    I've tried creating a view on the rec_containers table that is all the columns in the table plus 1 additional column that is
    nvl(shipment_id,split_shipment_id) comp_ship_id
    and set the relation to shipment_id=comp_shipment_id. I set the comp_shipment_id column to query yes and insert & update to no because I don't want to update that column in the view.
    The problem is I can't update any columns, I get a can't reserve record for update or delete error.
    Does anyone have any ideas how I can get the containers block to query all records where the shipment_id or split_shipment_id matches the shipment block shipment_id and still be able to update the records?
    Thanks for any help.

    Your idea of using a view is the best approach. In order to make the block updateable, you have to sst the property "Query only" for your derived item to "Yes". Witn this, the column will not be included in any further dml. About the locking... it may be that forms isn't anymore able to do proper locking when a block is based on a view. In that case, put an ON-LOCK-trigger on the block and lock the record by yourself doing y SELECT FOR UPDATE NOWAIT on the record. To just try if this would work you use a NULL in the ON-LOCK just to xheck if the dml-operations itself will work. if your view is based on only one table you have good chances that there is nothing to change, if you get an error like "View not updateable", you have to do some further adjustments
    -Set the key-Mode for the block to "Non-updateable"
    -Set the property "Primary key" to "Yes" for the pk-item in your block.
    hope this helps

  • Issue with Master Detail relation in OAF page -- Help

    Hi,
    I am developing an OA page with a master detail relation. The detail records are displayed in the subtab region.
    The issue that I am facing is as follows:
    If there are 2 detail records in the detail table, then my page is displaying these 2 records twice i.e.
    Detail Records:
    Header Id Line Id
    2 1
    3 1
    Header Id Line Id
    2 1
    3 1
    If the number of detail record increases, then again the display also increases that many times i.e. 3 records gets displayed thrice.
    Kindly help to figure out the issue.
    Thanks In Advance.

    Hi,
    Take the following actions.
    1. Try to display your records in simple Table and remove it from subtab,
    2. check relations as well, you can delete and re-create all the relations with EOs and VOs and recreate them.
    3. Also check when your VO get popluated that how many rows are there in Detail VO ?
    For example.
    int x = yourViewObject.getRowCount();
    System.out.println("Number of rows in detail view Object"+x);
    Haroon.

  • Master - Detail relation succeded and the failed!!

    Hi all,
    I've made a master-detail relation between two data block using data block wizard with (copy value from item) property, this worked successfully for times and failed a lot of times!
    when I insert a record at the master data block the value is copied at the detail data block, but when I did the same thing for another time the value didn't copy!!
    to solve this problem I made a trigger at the detail data block (pre insert):
    :Master.Item-Value := :Detail.Item-Value
    this one succeded for the first time and then it failed!!
    I don't know what is the problem
    Note:
    I connected to a database server on another PC and work and save my forms at this PC.
    Edited by: Dev. Musbah on Oct 5, 2008 3:54 AM

    One about the important note:
    Thats exactly the missing point.
    If you assign the PK-value by a database-trigger, you have to read it back into forms after the insert.
    Three possibilities:
    1. There is a property at block level like "DML returning clause" If set to "Yes", forms will read back all values from the db after insert or update.
    2. Write an POST-INSERT-trigger at block-level and read back the ID by yourself using a cursor.
    3. Assign the PK-value already in the form in a PRE-INSERT-trigger and populate the PK-column in the database-trigger only if the pk-column is null
    hope this helps.

  • Help on Master Detail relation

    Im using XSQL command line processor 1.0.2.0.
    How I can I write a SQL query To display master detil relation in the output?
    For example Department and Emp are two different tables with master detail relation...
    I just want to display the output some thing like..
    <Department>
    <Details>
    <Dep_name>Accounts</Dep_name>
    <Dep_no>10</Dep_no>
    <EMP>
    <EMP_NAME>AAAAAA</EMP_NAME>
    <EMP_NO>999999999</EMP_NO>
    <HRD>01/01/2000</HRD>
    </EMP>
    <EMP>
    <EMP_NAME>BBBBBB</EMP_NAME>
    <EMP_NO>100000000</EMP_NO>
    <HRD>01/01/2000</HRD>
    </EMP>
    </Details>
    <Details>
    <Dep_name>INVENTORY</Dep_name>
    <Dep_no>20</Dep_no>
    <EMP>
    <EMP_NAME>CCCCCCC</EMP_NAME>
    <EMP_NO>8888888888</EMP_NO>
    <HRD>01/01/2000</HRD>
    </EMP>
    <EMP>
    <EMP_NAME>BBBBBB</EMP_NAME>
    <EMP_NO>100000000</EMP_NO>
    <HRD>01/01/2000</HRD>
    </EMP>
    </Details>
    </Department>

    [list]
    [*]First, I'd recommend upgrading to XSQL 1.0.4.3, the latest production release that is part of the XDK for Java 8.1.7.1 at http://otn.oracle.com/tech/xml
    [*]Then, explore using the Oracle CURSOR() expression to create nested rowsets. This is documented in our SQL language reference info here on OTN. My book has several examples of using CURSOR() to produce master/detail results, too.
    [list]
    Steve Muench
    Development Lead, Oracle XSQL Pages Framework
    Lead Product Manager for BC4J and Lead XML Evangelist, Oracle Corp
    Author, Building Oracle XML Applications
    null

  • Multiple Master Detail Relation In Forms 6i

    I have tables as below
    1.Bill_Head
    Bill_No
    Bill_Date
    Fin_Year_Cd
    Remarks
    2.Bill_Tail
    Bill_No
    Product_Cd
    Amount
    Ded_Amount
    Net_Amount
    3.Bill_Tail_Det
    Bill_No
    Product_Cd
    Quantity
    Rate
    Interest_Percent
    Service_Charge
    Vat_Tax_Percent
    The Relation is like
    Between BILL_HEAD and BILL_TAIL is Master Details Relation
    Between BILL_TAIL and BILL_TAIL_DET is one to one relation
    In single form i am not able to insert record.
    If i build Master details between BILL_HEAD and BILL_TAIL, BILL_TAIL and BILL_TAIL_DET, when i run the for to insert data.
    I will put the data for BILL_HEAD data
    For this parent record there will be child record in BILL_TAIL block.
    For this BILL_TAIL parent record there may be a child record in BILL_TAIL_DET or may not. Suppose i put a child in BILL_TAIL_DET.
    Then i wanted put one more child record in BILL_TAIL block, if i say next record, it is asking me to "save the record first".
    Please help me in this regards
    my mail id : [email protected]
    Regards
    Mahaveer
    Message was edited by:
    user603318

    Thanks Kris, for your reply.
    Is there any way out to enter all the data at once and then commit, b'cse for every record asking to commit is tedius.
    Regards
    Mahaveer

  • Serious problem with previous / next record in master-details relations

    I have master-details relations like this (if master is A) :
    A-B
    A-C and C-D
    When I move down with do_key('next_record') all values of all records in all blocks are OK. But when I move up, it doesn't work : all D block values are erased and I don't understand why ?
    Thank you for your help.
    Antoine LEFEBVRE.

    Blocks A and B are in the first canvas and blocks C et D are in the second canvas.
    On next_record action from A the B is updated, C too and D too. But on previous_record action, D is not updates.
    To display the second canvas I use a command button and into the WBP trigger there is :
    go_block(C);
    execute_query;
    to be sure to execute query, but it's null.
    What's your suggest ?
    Thank you,
    Antoine.

  • Master-Detail Relation- Detail records not displaying

    Hi All,
    I am working forms(10g) customization for an oracle applications. our requirement is to develop a new window(screen) which should display all the related child records for the master record in the main form on a button press.
    i have developed a new database block based on a vew and provided the relation with master block, and done the required customization.
    But, when i run the form, and clicked on button, it is giving an error
    FRM-40350 Query caused no records to be retrieved.below is the code that i have written on button click
    BEGIN
              IF event = 'WHEN-BUTTON-PRESSED'
              THEN
              SHOW_VIEW('XXSCP_GBL_CUST_PEGGING_CON');
              SHOW_VIEW('XXSCP_GBL_CUST_PEGGING_STK');
              app_window.set_window_position('XXSCP_GBL_CUST_PEGGING_WIN',
                                             'CASCADE',
                                             'XXSCP_GBL_EXCEP_DETAILS_WIN');
          SET_BLOCK_PROPERTY('XXSCP_GBL_EXP_DETAIL_V',NEXT_NAVIGATION_BLOCK,'XXSCP_GBL_CUST_PEG_V');                                        
          GO_BLOCK('XXSCP_GBL_CUST_PEG_V');
         -- fnd_message.DEBUG('before execute');
          EXECUTE_QUERY;
          :parameter.p_excep_detail := 'FALSE';
              ELSE
                   NULL;
              END IF;
              EXCEPTION
                   WHEN OTHERS
                   THEN
                   fnd_message.DEBUG('other error at button press'||SQLERRM);
              --     NULL;
    END;I am able to query records in my view from database, but not working when i run the form.
    ANy suggestion will be helpful.
    Thanks in advance,
    pavan

    Duplicate post -- Re: Master-Detail Relation- Detail records not displaying

  • Master Detail Relation

    Can I design Master detail using one block for master and display like 5 records and each of this has 10 detail records. I am not sure if I can achieve this.
    Other scenario is have one master block(5 records) and have 5 detail blocks. Please give any information related

    Husna,
    1. To only show 5 reords in teh master block, just set the display record property to 5 (records displayed). Selecting one of teh master records queries the detail records (as many as there are available)
    2. Master/Detail navigation works only for the current selected master record. i get th eimpression that you want to show all detail records that belong to the five master records currently visible. If this is the case then I would'nt use a master-detail relation in Forms, but read the PK from the block record and set it as the where clause to one of the detail blocks.
    Frank

  • Creating a master-detail relation between a view and a table

    Hi all,
    I have a problem with creating a master-detail relation between a database-view with lots of customer data and a small table with per customer a list of entities of our companies who may work for that customer.
    Somehow I seem to be unable to create a relation between these two. I can't find where I can make a foreign key using Toplink to implement the relationship. And neither can I get a Viewlink object doing the job using ADF Business Components.
    Somebody any suggestions on this problems?
    Regards,
    Birgit

    There is a key relationship between two fields which form the primary key in the main table of the view and two fields in the second table.
    I created a viewlink manually, but I still couldn't get the data correct i.e. a form with one record of a customer from the main view and a small table with all entities of our company who can make performances for that customer.
    I tried to find a manual or a how-to on this topic but I didn't find anything helpfull yet.
    Regards,
    Birgit
    After a couple more tries, I got the master-detail working. With all the fiddling I am not sure what caused the problem but I think the finally action was checking which fields of the view were marked as primary keys.
    Now everthing is up and running.
    Birgit
    Message was edited by:
    user492355

  • Problem occured when create a tree table for master-detail view objects using SQL queries?

    I am programming a tree table for master-detail view objects using SQL queries and these 2 view objects are not simple singel tables queries, and 2 complex SQL are prepared for master and view objects. see below:
    1. Master View object (key attribute is SourceBlock and some varaible bindings are used for this view object.)
    SELECT  cntr_list.SOURCE_BLOCK,                   
            sum(                   
             case when cntr_list.cntr_size_q = '20'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr20 ,                   
            sum(                   
             case when cntr_list.cntr_size_q = '40'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr40 ,                   
             sum(                   
             case when cntr_list.cntr_size_q = '45'                   
                  then cntr_list.cntr_qty                   
                  else 0 end ) as cntr45                    
    FROM (       
        SELECT yb1.BLOCK_M as SOURCE_BLOCK,       
               scn.CNTR_SIZE_Q,        
               count(scn.CNTR_SIZE_Q) AS cntr_qty        
        FROM  SHIFT_CMR scm, SHIFT_CNTR scn, YARD_BLOCK yb1, YARD_BLOCK yb2       
        WHERE       
        scm.cmr_n = scn.cmr_n             
        AND (scm.plan_start_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS')                 
        OR scm.plan_end_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS'))                 
        AND scm.shift_mode_c = :ShiftModeCode                           
        AND scm.end_terminal_c = :TerminalCode      
        AND scm.start_terminal_c = yb1.terminal_c                  
        AND scm.start_block_n = yb1.block_n                  
        AND substr(scn.start_location_c,(instr(scn.start_location_c,',',1,5)+1),instr(scn.start_location_c,',',1,6)-(instr(scn.start_location_c,',',1,5)+1)) BETWEEN yb1.slot_from_n AND yb1.slot_to_n                  
        AND scm.end_terminal_c = yb2.terminal_c                  
        AND scm.end_block_n = yb2.block_n                  
        AND substr(scn.end_location_c,(instr(scn.end_location_c,',',1,5)+1),instr(scn.end_location_c,',',1,6)-(instr(scn.end_location_c,',',1,5)+1)) BETWEEN yb2.slot_from_n AND yb2.slot_to_n           
        AND scn.status_c not in (1, 11)             
        AND scn.shift_type_c = 'V'             
        AND scn.source_c = 'S'       
        GROUP BY yb1.BLOCK_M, scn.CNTR_SIZE_Q       
    ) cntr_list       
    GROUP BY cntr_list.SOURCE_BLOCK
    2. Detail View object (key attributes are SourceBlock and EndBlock and same varaible bindings are used for this view object.)
    SELECT  cntr_list.SOURCE_BLOCK, cntr_list.END_BLOCK,                
            sum(                     
             case when cntr_list.cntr_size_q = '20'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr20 ,                     
            sum(                     
             case when cntr_list.cntr_size_q = '40'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr40 ,                     
             sum(                     
             case when cntr_list.cntr_size_q = '45'                     
                  then cntr_list.cntr_qty                     
                  else 0 end ) as cntr45                      
    FROM (         
        SELECT yb1.BLOCK_M as SOURCE_BLOCK,     
               yb2.BLOCK_M as END_BLOCK,  
               scn.CNTR_SIZE_Q,          
               count(scn.CNTR_SIZE_Q) AS cntr_qty          
        FROM  SHIFT_CMR scm, SHIFT_CNTR scn, YARD_BLOCK yb1, YARD_BLOCK yb2         
        WHERE         
        scm.cmr_n = scn.cmr_n               
        AND (scm.plan_start_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS')                   
        OR scm.plan_end_dt BETWEEN to_date(:DateFrom,'YYYY/MM/DD HH24:MI:SS') AND to_date(:DateTo,'YYYY/MM/DD HH24:MI:SS'))                   
        AND scm.shift_mode_c = :ShiftModeCode                             
        AND scm.end_terminal_c = :TerminalCode        
        AND scm.start_terminal_c = yb1.terminal_c                    
        AND scm.start_block_n = yb1.block_n                    
        AND substr(scn.start_location_c,(instr(scn.start_location_c,',',1,5)+1),instr(scn.start_location_c,',',1,6)-(instr(scn.start_location_c,',',1,5)+1)) BETWEEN yb1.slot_from_n AND yb1.slot_to_n                    
        AND scm.end_terminal_c = yb2.terminal_c                    
        AND scm.end_block_n = yb2.block_n                    
        AND substr(scn.end_location_c,(instr(scn.end_location_c,',',1,5)+1),instr(scn.end_location_c,',',1,6)-(instr(scn.end_location_c,',',1,5)+1)) BETWEEN yb2.slot_from_n AND yb2.slot_to_n             
        AND scn.status_c not in (1, 11)               
        AND scn.shift_type_c = 'V'               
        AND scn.source_c = 'S'         
        GROUP BY yb1.BLOCK_M, yb2.BLOCK_M, scn.CNTR_SIZE_Q         
    ) cntr_list         
    GROUP BY cntr_list.SOURCE_BLOCK, cntr_list.END_BLOCK
    3. I create a view link to create master-detail relationship for these 2 view objects.
    masterview.SourceBlock (1)->detailview.SourceBlock (*).
    4. I create a tree table using these 2 view objects with master-detail relationship.
    When I set default value for variable bindings of these 2 view objects and the matching records exist, tree table can work well. I can expand the master row to display detail row in UI.
    But I need to pass in dymamic parameter value for variable bindings of these 2 view objects, tree table cannnot work again. when I expand the master row and no detail row are displayed in UI.
    I am sure that I pass in correct parameter value for master/detail view objects and matching records exist.
    Managed Bean:
            DCIteratorBinding dc = (DCIteratorBinding)evaluteEL("#{bindings.MasterView1Iterator}");
            ViewObject vo = dc.getViewObject();
            System.out.println("Before MasterView1Iterator vo.getEstimatedRowCount()="+ vo.getEstimatedRowCount());
            System.out.println("Before MasterView1Iterator ShiftModeCode="+ vo.ensureVariableManager().getVariableValue("ShiftModeCode"));
            vo.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
            vo.ensureVariableManager().setVariableValue("DateTo", dateTo);
            vo.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
            vo.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
            vo.executeQuery();
            System.out.println("MasterView1Iterator vo.getEstimatedRowCount()="+ vo.getEstimatedRowCount());
            DCIteratorBinding dc1 = (DCIteratorBinding)evaluteEL("#{bindings.DetailView1Iterator}");
            ViewObject vo1 = dc1.getViewObject();
            System.out.println("Before DetailView1Iterator vo1.getEstimatedRowCount()="+ vo1.getEstimatedRowCount());
            System.out.println("Before DetailView1Iterator ShiftModeCode="+ vo1.ensureVariableManager().getVariableValue("ShiftModeCode"));
            vo1.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
            vo1.ensureVariableManager().setVariableValue("DateTo", dateTo);
            vo1.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
            vo1.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
            vo1.executeQuery();
            System.out.println("after DetailView1Iterator vo1.getEstimatedRowCount()="+ vo1.getEstimatedRowCount());
    5.  What's wrong in my implementation?  I don't have no problem to implement such a tree table if using simple master-detail tables view object, but now I have to use such 2 view objects using complex SQL for my requirement and variable bindings are necessary for detail view object although I also think a bit strange by myself.

    Hi Frank,
    Thank you and it can work.
    public void setLowHighSalaryRangeForDetailEmployeesAccessorViewObject(Number lowSalary,
                                                                              Number highSalary) {
            Row r = getCurrentRow();
            if (r != null) {
                RowSet rs = (RowSet)r.getAttribute("EmpView");
                if (rs != null) {
                    ViewObject accessorVO = rs.getViewObject();
                    accessorVO.setNamedWhereClauseParam("LowSalary", lowSalary);
                    accessorVO.setNamedWhereClauseParam("HighSalary", highSalary);
                executeQuery();
    but I have a quesiton in this way. in code snippet, it is first getting current row of current master VO to determine if update variables value of detail VO. in my case, current row is possibly null after executeQuery() of master VO and  I have to change current row manually like below.
    any idea?
                DCIteratorBinding dc = (DCIteratorBinding)ADFUtil.evaluateEL("#{bindings.SSForecastSourceBlockView1Iterator}");
                ViewObject vo = dc.getViewObject();           
                vo.ensureVariableManager().setVariableValue("DateFrom", dateFrom);
                vo.ensureVariableManager().setVariableValue("DateTo", dateTo);
                vo.ensureVariableManager().setVariableValue("ShiftModeCode", shiftModeC);
                vo.ensureVariableManager().setVariableValue("TerminalCode", terminalCode);
                vo.executeQuery();
                vo.setCurrentRowAtRangeIndex(0);
                ((SSForecastSourceBlockViewImpl)vo).synchornizeAccessorVOVariableValues();

  • Master-Details Relation

    Hi All,
    I Have one dought,I have a form with master-detail relation.
    If i query in header level i can able to see all the data in both levels.
    If i query in detail level i cannot see header level information,but i can able to see the detail level only.
    Can any help me in this
    Regards
    Siva

    Remove join condition and relation as well! In master block you should have in where close "database_item = :bl_2.item" and in detail block you should have where close with "database_item = :bl_1.item". When user put the cursor in bl_1 and execute query the bl_2 should be listed as well. You can do this on different way for ex.: write in key-exeqry or when-new-record-instance etc. on bl_1 go_block('bl_2'); execute_query; And inversely or "vice versa": when user put the cursor in bl_2 and execute query the bl_1 should be listed as well. You can do this on the same way for ex.: write in key-exeqry on bl_2 go_block('bl_1'); execute_query;
    If you want to create record you have to be carefuly on the key items in both blocks. So you have to fill the key item before user want to do the commit form. That's all but I did not test it so I can not know how could both where condition behave with different users action.

  • About master detail relation ship between tables

    Hi
    I am using jdev 11.1.1.5.0
    Use case:
    I have 2 table having master-detail relationship
    master table - req_hdr
    detail table - req_file
    req_hdr is drop as adf table (t1) on a fragment page and req_file is drop on popup as adf table (t2).
    user can add any no of row in req_file with respect to each row of req_hdr.
    to open popup for req_file, a command image link is provided in one column of req_hdr.
    On popup, there is two button provided for save and close.
    On save button,commit operation is performed and on close button,rollback operation and popup.hide() is performed.
    Now the problem what I am facing is
    1. If with respect to any row of req_hdr there is one row already exist in req_file and user click on add button to add new row in req_file and randomly user decide to to close the popup rollback operation is performed and again when user click on same row to open popup.
    Popup contains no row while in database there is one row exist for that.
    2. if user add a new row in req_file and perform save( commit ) and again for next row of req_hdr user open a popup to add new row in req_file and click on add button ,values of preceding row is already populated in new row while is should be empty because req_hdr and req_file have master detail relation and for next id of req_hdr, req_file should display new row.
    Anyone have the solution regarding this....?
    Thanks..

    the contentDelivery for the popup is already set to lazyUncached
    and on add button i use following code to add new row:--
    <code>
    Row r_file=null;
    CollectionModel tableModel = (CollectionModel)getT2().getValue();
    JUCtrlHierBinding adfModel = (JUCtrlHierBinding)tableModel.getWrappedData();
    DCIteratorBinding dciter = adfModel.getDCIteratorBinding();
    NavigatableRowIterator nav=dciter.getNavigatableRowIterator();
    r_file=nav.createRow();
    r_file.setNewRowState(Row.STATUS_INITIALIZED);
    Row lastRow=nav.last();
    int r_index=nav.getRangeIndexOf(lastRow);
    nav.insertRowAtRangeIndex(r_index+1, r_file);
    dciter.setCurrentRowWithKey(r_file.getKey().toStringFormat(true));
    r_file.setAttribute("Sno", vo_file.getEstimatedRowCount());
    r_file.setAttribute("Filetype", null);
    r_file.setAttribute("Filename", null);
    r_file.setAttribute("Remark", null);
    </code>
    There is any help regarding this....?

  • Https: access to the SQL report SQL2012

    Hi,
    I just successfully bind the https to the SQL reporting, however, I cannot access the report Manager or reports thereafter although I am sure I provide the correct user name/password (even tried Administrator), after 3 attampts, a blank page is shown...
    Please help on how to fix it...
    Event log also thrown out the error message .. (event id 110)
    The value for UrlRoot in RSReportServer.config is not valid. The default value will be used instead.

    -------Details--------
    System.Net.WebException: The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel. ---> System.Security.Authentication.AuthenticationException: The remote certificate is invalid according to the validation
    procedure.
       at System.Net.Security.SslState.StartSendAuthResetSignal(ProtocolToken message, AsyncProtocolRequest asyncRequest, Exception exception)
       at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(ProtocolToken message, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartSendBlob(Byte[] incoming, Int32 count, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.ProcessReceivedBlob(Byte[] buffer, Int32 count, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartReadFrame(Byte[] buffer, Int32 readBytes, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(ProtocolToken message, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartSendBlob(Byte[] incoming, Int32 count, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.ProcessReceivedBlob(Byte[] buffer, Int32 count, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartReadFrame(Byte[] buffer, Int32 readBytes, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(ProtocolToken message, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartSendBlob(Byte[] incoming, Int32 count, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.ProcessReceivedBlob(Byte[] buffer, Int32 count, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartReadFrame(Byte[] buffer, Int32 readBytes, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(ProtocolToken message, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.StartSendBlob(Byte[] incoming, Int32 count, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.ForceAuthentication(Boolean receiveFirst, Byte[] buffer, AsyncProtocolRequest asyncRequest)
       at System.Net.Security.SslState.ProcessAuthentication(LazyAsyncResult lazyResult)
       at System.Net.TlsStream.CallProcessAuthentication(Object state)
       at System.Threading.ExecutionContext.runTryCode(Object userData)
       at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData)
       at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Net.TlsStream.ProcessAuthentication(LazyAsyncResult result)
       at System.Net.TlsStream.Write(Byte[] buffer, Int32 offset, Int32 size)
       at System.Net.PooledStream.Write(Byte[] buffer, Int32 offset, Int32 size)
       at System.Net.ConnectStream.WriteHeaders(Boolean async)
       --- End of inner exception stack trace ---
       at System.Web.Services.Protocols.WebClientProtocol.GetWebResponse(WebRequest request)
       at System.Web.Services.Protocols.HttpWebClientProtocol.GetWebResponse(WebRequest request)
       at Microsoft.ReportingServices.UI.Global.RSWebServiceWrapper.GetWebResponse(WebRequest request)
       at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
       at Microsoft.SqlServer.ReportingServices2010.ReportingService2010.ListItemTypes()
       at Microsoft.SqlServer.ReportingServices2010.RSConnection2010.<ListItemTypes>b__10f()
       at Microsoft.SqlServer.ReportingServices2010.RSConnection2010.SoapMethodWrapper`1.ExecuteMethod(Boolean setConnectionProtocol)
       at Microsoft.SqlServer.ReportingServices2010.RSConnection2010.ListItemTypes()
       at Microsoft.ReportingServices.UI.Global.SecureAllAPI()
       at Microsoft.ReportingServices.UI.ReportingPage.EnsureHttpsLevel()
       at Microsoft.ReportingServices.UI.ReportingPage.ReportingPage_Init(Object sender, EventArgs args)
       at System.EventHandler.Invoke(Object sender, EventArgs e)
       at System.Web.UI.Control.OnInit(EventArgs e)
       at System.Web.UI.Page.OnInit(EventArgs e)
       at System.Web.UI.Control.InitRecursive(Control namingContainer)
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    appdomainmanager!ReportManager_0-1!c30!03/11/2015-16:43:25:: e ERROR: Remote certificate error RemoteCertificateNameMismatch encountered for url
    https://aaa.xxx.yyy/ReportServer_SQLEXPRESS/ReportService2010.asmx.
    ui!ReportManager_0-1!c30!03/11/2015-16:43:25:: e ERROR: System.Threading.ThreadAbortException: Thread was being aborted.
       at System.Threading.Thread.AbortInternal()
       at System.Threading.Thread.Abort(Object stateInfo)
       at System.Web.HttpResponse.End()
       at System.Web.HttpServerUtility.Transfer(String path, Boolean preserveForm)
       at Microsoft.ReportingServices.UI.ReportingPage.ShowErrorPage(String errMsg)
    library!WindowsService_0!748!03/11/2015-16:44:32:: i INFO: Call to CleanBatch()
    library!WindowsService_0!748!03/11/2015-16:44:32:: i INFO: Cleaned 0 batch records, 0 policies, 0 sessions, 0 cache entries, 0 snapshots, 0 chunks, 0 running jobs, 0 persisted streams, 0 segments, 0 segment mappings, 0 edit sessions.
    library!WindowsService_0!748!03/11/2015-16:44:32:: i INFO: Call to CleanBatch() ends
    Indeed, this is a testing VM that I P2V from the live server which domain name is aaa.xxx.yyy but I already changed the host file and now I accessing this VM is using
    https://project.bbb.ccc/. Not sure why it still hardcoded as aaa.xxx.yyy.
    Would this generated the problem...

Maybe you are looking for

  • Problem exporting transparant .gif

    Hi guys, I created some text and applied the 'Dark Chrome 02' effect to it. I went to export wizard, selected .gif and index transparancy. All seemed good. But I noticed it had a white Matte. I changed that to transparant but it ends up making it bla

  • Can't boot into Mac Partition

    I started out with a simple error in iTunes whenever I tried to update my genius. The error was the following: "We could not complete your iTunes Store request. An unknown error occured (-9812). There was an error in the iTunes Store. Please try agai

  • IDOC adapter question

    I am trying to set up a simple file to IDOC transaction ( as a poc ), and I think that I havent configured my IDOC reciever channel properly. I used IDX1 to get the port, and RFC destination information. When I used the wizard, it said that the chann

  • Automatic File Sync/Transfer to PC/E-Mail etc.

    Hi, I have the following request/problem for my nokia 6280. Some days ago I "discovered" the voice recording feature, which I now using more than 20 times a day. I send them to my secretary and she executes my orders. Now I want to automize this file

  • How to configure iMac and Airport Extreme for remote access?

    I want  to view videos stored in iTunes on my iMac remotely over the Internet when I away from my home network.  My home network setup includes AirPort Extreme with Comcast High Speed Internet Service (16Mbs/6Mbps).  I use AirPlayit to support the iM