Oracle BPEL 2.0 - add the child node

Hi guys,.

SOA 11.1.1.7, BPEL 2.0

I have a child screaming master BPEL BPEL flow flow in a ForEach loop.

I have part of the answer like this:

< caseResponses >

< caseResponse >... < / caseResponse >

< caseResponse >... < / caseResponse >

< / caseResponses >

CaseResponse items come from child BPEL flows.

I'm trying to add each of these elements in the element parent < caseResponses > but when running I get "The Exception is thrown because the in-specs on the 112 line are assessed to be empty," where the line 112 is the line append.

My code is:

< assign the name = "AppendToResponse" >

< extensionAssignOperation >

< bpelx: Add >

< bpelx: go > $InvokeHandleSingleCarglassCase_process_OutputVariable.payload / ns1:caseResponse < / bpelx: go >

< bpelx: to > $outputVariable.payload / client: caseResponses < / bpelx: to >

< / bpelx: Add >

< / extensionAssignOperation >

< / assign >

If I add a copy - just like a test rule-

< assign the name = "AppendToResponse" >

< copy >

< a > $InvokeHandleSingleCarglassCase_process_OutputVariable.payload / ns1:caseResponse < / from >

< to > $outputVariable.payload/client:caseResponses/client:caseResponse < /pour >

< / copy >

< extensionAssignOperation >

< bpelx: Add >

< bpelx: go > $InvokeHandleSingleCarglassCase_process_OutputVariable.payload / ns1:caseResponse < / bpelx: go >

< bpelx: to > $outputVariable.payload / client: caseResponses < / bpelx: to >

< / bpelx: Add >

< / extensionAssignOperation >

< / assign >

I works as expected: all caseResponse items are added and there is also one more copy activity.

What can I do so that I don't get the "The Exception is thrown because the in-specs on the 112 line are assessed to be empty" exception without copy assign?

Thank you!

By the way

Rather than add it, you can use the copy, but instead of the normal copy you must change the code a bit to something like:

$InvokeHandleSingleCarglassCase_process_OutputVariable.payload / ns1:caseResponse

$outputVariable.payload / client: caseResponses[$ForEachCounter]/ client: caseResponse

If you add the counter and checks that I wrote in the previous answer basically it will create a node at position x (x being the value of the counter) and the copy of your result

Tags: Fusion Middleware

Similar Questions

  • Click the step of node in the child node has no

    Hello

    I customized a series of nodes personalized like "chassisRackVSphere-ui.

    In the picture1 below, "10.240.198.192", "Shopping cart", "Châssis" all three are custom node. When I double click on the column in the table, it must enter the purpose of the grid and remain in the child node as photo 2.

    But it will show the Note2 for a second, then jump to the pic1. This jump is abnormal. An idea for this problem?

    todelete.png

    todelete2.png

    Set a breakpoint in your data adapter to see what happens when you select the custom in the 1st case object. The error of the user interface must be the result of bad data.

  • Add the new node to the 2 Oracle11gR2 CCR node

    Dear all,

    I'm working on 2 node RAC clusterware in oracle 11 g 2. But a question comes in my mind if one of my node to node 2 CCR does not work let rac1 and rac2 are 2 knots and rac1 does not work or let say destroyed, is it possible to add a new node say node 3, which will work with node 2. As db works well on node 2.

    Advice kindly during the same period.

    Yes. The Oracle Docs for more information

    https://docs.Oracle.com/database/121/CWADD/adddelclusterware.htm

  • Add the error node

    Hello

    I try to add the node two-node Oracle 11g RAC, but I had
    a mistake. I follow the steps:
    # export ORACLE_HOME=/u01/app/11.2.0/grid
    # cd $ORACLE_HOME/oui/bin
    # ./addNode.sh -silent "CLUSTER_NEW_NODES={rac3}" "CLUSTER_NEW_VIRTUAL_HOSTNAMES={rac3-vip}"
    For example, the following in the log file:
    INFO: Environment Variables:
    
    INFO:   ORACLE_HOME = /u01/app/11.2.0/grid
    
    INFO:   PATH = /u01/app/oracle/product/11.2.0/db_1/bin:/usr/sbin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/oracle/b
    in
    
    INFO:   CLASSPATH =
    
    INFO: Username:oracle
    
    INFO: Install area Control created with access level  1
    
    INFO: Oracle Universal Installer version is 11.2.0.1.0
    
    INFO: Setting variable 'ORACLE_HOME' to '/u01/app/11.2.0/grid'. Received the value from the command line.
    INFO: Setting variable 'CLUSTER_NEW_NODES' to 'rac3'. Received the value from the command line.
    INFO: Setting variable 'CLUSTER_NEW_VIRTUAL_HOSTNAMES' to 'rac3-vip'. Received the value from the command line.
    INFO: Setting variable 'PREREQ_CONFIG_LOCATION' to ''. Received the value from variable association.
    INFO: Setting variable 'FROM_LOCATION' to '/u01/app/11.2.0/grid/inventory/ContentsXML/comps.xml'. Received the value from a co
    de block.
    INFO: Setting variable 'ROOTSH_LOCATION' to '/u01/app/11.2.0/grid/root.sh'. Received the value from a code block.
    INFO: Setting variable 'ROOTSH_STATUS' to '3'. Received the value from a code block.
    INFO: Setting variable 'ORACLE_HOME' to '/u01/app/11.2.0/grid'. Received the value from the command line.
    INFO: Setting variable 'CLUSTER_NEW_NODES' to 'rac3'. Received the value from the command line.
    INFO: Setting variable 'CLUSTER_NEW_VIRTUAL_HOSTNAMES' to 'rac3-vip'. Received the value from the command line.
    INFO: Setting variable 'PREREQ_CONFIG_LOCATION' to ''. Received the value from variable association.
    INFO: Setting variable 'FROM_LOCATION' to '/u01/app/11.2.0/grid/inventory/ContentsXML/comps.xml'. Received the value from a code block.
    INFO: Setting variable 'ROOTSH_LOCATION' to '/u01/app/11.2.0/grid/root.sh'. Received the value from a code block.
    INFO: Setting variable 'ROOTSH_STATUS' to '3'. Received the value from a code block.
    INFO:
    *** Welcome Page***
    INFO: Setting variable 'ORACLE_HOME_NAME' to 'Ora11g_gridinfrahome1'. Received the value from a code block.
    INFO: SRVM ClusterInfo.IsLocalOnly() called. Return value obtained is 'true'.
    INFO: The CRS clusterware location for 'oracle.crs 10.1.0.2.0' is '/u01/app/11.2.0/grid'.
    INFO: CRS clusterware detected.
    INFO: Vendor clusterware is not detected.
    INFO: Local node 'rac1' is derived from the Oracle home properties.
    INFO: Setting variable 'LOCAL_NODE' to 'rac1'. Received the value from a code block.
    INFO: Setting variable 'EXISTING_REMOTE_NODES' to 'rac2'. Received the value from a code block.
    INFO: Setting variable 'REMOTE_NODES' to 'rac3'. Received the value from a code block.
    INFO: Setting the 'ExistingClusterNodes' property to 'rac1,rac2'.
    INFO: Setting the 'EnableVirtualHostNameEntry' property to 'true'.
    INFO: Setting the 'NewNodes ( CLUSTER_NEW_NODES )' property to 'rac3'. Received the value from the command line.
    INFO: Setting variable 'REMOTE_NODES' to 'rac3'. Received the value from a code block.
    INFO: Setting variable 'CLUSTER_NODES' to 'rac1,rac2,rac3'. Received the value from a code block.
    INFO: Performing tests to see whether nodes rac2,rac3 are available
    INFO: Validating nodes rac2...
    INFO: Checking if nodes are alive...
    INFO: Validating user equivalence...
    INFO: Validating nodes rac3...
    INFO: Checking if nodes are alive...
    INFO: Validating user equivalence...
    INFO: Status of nodes in the cluster:
    Status of node 'rac2':
    Node is okay
    
    Status of node 'rac3':
    null
    
    --------------------------------------------------------------------------
    
    SEVERE: The selected remote nodes 'rac3' are not accessible.
    INFO: User Selected: Yes/OK
    When I try to ping for the new node, it is correct.

    So, can you help me, please?

    Thank you very much.

    Hello

    You can cancel the configuration performed by root.sh using the following:

    /U01/app/11.2.0/grid/CRS/install/rootcrs.pl - deconfig-force

    Thus, after the above command, you can perform the root.sh again.

    Kind regards.

  • Tree view does not update when you add the first node to node expanded

    Hello

    Please take a look in the following code. To reproduce the incorrect behavior, you must expand the item, then click on the button 'Add' and observe, that nothing is happening. Collapse, then developing the watch node children added. I use Flex 3.5.0

    Is this a bug in the SDK, or am I missing a switch of AutoUpdate?

    Thank you!!

    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="horizontal" 
         minWidth="955" minHeight="600"
         creationComplete="run()">
         
         <mx:Tree id="tree" width="300" height="500" labelField="name" />
         
         <mx:Button label="add" click="onClickAdd()" />
         
         <mx:Script>
              <![CDATA[
                   import mx.collections.ArrayCollection;
                   import mx.utils.ObjectProxy;
                   
                   protected var itm1:Object;
                   
                   
                   protected function run() : void
                   {
                        var ac:ArrayCollection = new ArrayCollection();
                        
                        this.itm1 = new ObjectProxy({name:"1", children:new ArrayCollection()});
                        ac.addItem(this.itm1);
                        this.tree.dataProvider = ac;
                   }
                   
                   
                   protected function onClickAdd() : void
                   {
                        this.itm1.children.addItem({name:"child"});
                   }
              ]]>
         </mx:Script>
         
    </mx:Application>
     
    

    I think that your case is equivalent to "loading lazy trees."  There are examples

    around the internet.  I think you need to use a custom ITreeDataDescriptor

    which returns true for hasChildren.

  • Combine the child nodes

    Hello

    We use BI Publisher incorporated in Oracle EBS 12.1.3

    The XML produced by definition DATA has following structure (mocked up for simplicity)

    <DOC_DATA>
         <DOC_FLOW>
              <DOC_ID>1456</DOC_ID>
              <DOC_RECIPIENT>[email protected]</DOC_RECIPIENT>
              <DOC_DETAIL>
                   <DOC_NAME>ALERT</DOC_NAME>
                   <DOC_DATE>14-Jan-2013</DOC_DATE>
                   <DOC_DESC>test data 1</DOC_DESC>
              <DOC_DETAIL>
         </DOC_FLOW>
         <DOC_FLOW>
              <DOC_ID>1456</DOC_ID>
              <DOC_RECIPIENT>[email protected]</DOC_RECIPIENT>
              <DOC_DETAIL>
                   <DOC_NAME>EOL</DOC_NAME>
                   <DOC_DATE>10-Jan-2013</DOC_DATE>
                   <DOC_DESC>test data 2</DOC_DESC>
              <DOC_DETAIL>
         </DOC_FLOW>
         <DOC_FLOW>
              <DOC_ID>1456</DOC_ID>
              <DOC_RECIPIENT>[email protected]</DOC_RECIPIENT>
              <DOC_DETAIL>
                   <DOC_NAME>PACKAGING</DOC_NAME>
                   <DOC_DATE>20-Jan-2013</DOC_DATE>
                   <DOC_DESC>test data 3</DOC_DESC>
              <DOC_DETAIL>
         </DOC_FLOW>
         <DOC_FLOW>
              <DOC_ID>1798</DOC_ID>
              <DOC_RECIPIENT>[email protected]</DOC_RECIPIENT>
              <DOC_DETAIL>
                   <DOC_NAME>ALERT</DOC_NAME>
                   <DOC_DATE>11-Jan-2013</DOC_DATE>
                   <DOC_DESC>test data 4</DOC_DESC>
              <DOC_DETAIL>
         </DOC_FLOW>
    </DOC_DATA>
    

    Power required of the RTF template is:

    DOC - ID: 1456

    NAME of DOC DATE of the DOC DOC / / DESC
    DRAW THE ATTENTION OFJanuary 14, 2013test data 1
    EOL
    January 10, 2013test data 2
    PACKAGINGJanuary 20, 2013test data 3

    DOC - ID: 1798

    NAME of DOC DATE of the DOC DOC / / DESC
    DRAW THE ATTENTION OFJanuary 11, 2013test data 4


    * End of the report

    How should we write it for each logical grouping such as the child under the annual common parent element (1456, for example) can be printed together?

    Thanks for your contributions!

    XML is not well-formed

    DRAW THE ATTENTION OF

    January 14, 2013

    test data 1

    must be

    DRAW THE ATTENTION OF

    January 14, 2013

    test data 1

    / DOC_DETAIL >

    for your output, you can use

    Doc - id:

    Name of doc

    Date of the doc

    Doc / / Desc

  • Adjust the position of the child node in a StackPane

    Hello

    I have a question on the setting the positions of child nodes in a StackPane.
    I added 2 child nodes to a StackPane.
    For the 1st child node, I need to be always as big as the parent StackPane.
    For the 2nd child node, it should be as large as necessary to place a few small pictures and it must always be "anchored" to the upper right of the parent StackPane.
    2 childs nodes will be overlapping always.
    Is this doable with a StackPane or would it be better to use another class of component?

    Thank you.

    Yes, you can do it in a StackPane.
    The first node of a subclass of component and ensure that it has an unlimited width and max height and it will completely fill the available surface of the StackPane.
    Use the static StackPane.setAlignment (node, Pos) method to position the knot 2.

    import javafx.application.Application;
    import javafx.geometry.Pos;
    import javafx.scene.Scene;
    import javafx.scene.layout.*;
    import javafx.scene.paint.Color;
    import javafx.scene.shape.Rectangle;
    import javafx.stage.Stage;
    
    public class StackPanePositioning extends Application {
      public static void main(String[] args) throws Exception { launch(args); }
      @Override public void start(final Stage stage) throws Exception {
        Pane n1 = new Pane();
        n1.setPrefSize(200, 120);
        n1.setStyle("-fx-background-color: green;");
        Rectangle n2 = new Rectangle(50, 50,   Color.RED);
        StackPane.setAlignment(n2, Pos.TOP_RIGHT);
    
        StackPane stack = new StackPane();
        stack.getChildren().addAll(n1, n2);
        stage.setScene(new Scene(stack));
        stage.show();
      }
    }
    
  • How to find the child nodes of XMLDoc where-&gt; var XMLDoc = subform.datanode.saveXML("pretty");

    Hi all

    I am very new to the designer of the ADEP.  Please help me with this problem.

    Let's say that the Subform.datanode.saveXML () returns a XML as below.

    < test >

    < Paper1 > English < / Document1 >

    Science < paper2 > < / paper2 >

    History of < paper3 > < / papier3 >

    < test >

    In the script:

    var XMLDoc = subform.datanode.saveXML ("pretty");

    for (nodeCount = 0; nodeCount < XMLDoc.nodes.length; nodeCount ++)

    Returns an error "error: null is not an object.  But I was able to access the values by specifying directly "XMLDoc.paper1 [0] m:System.NET.SocketAddress.ToString ();"

    Can someone please suggest a way to know the number of child nodes in this context?

    Hello

    You can count the knots by:

    subform.datanode.nodes.item(0).nodes.length;
    
  • XML E4X nodes select based on the attribute of the child node.

    Hey,.

    I'm making a selection on the following XML code.

    I want to retrieve the list of the variable node when its child nodes metadata attribute 'name' is not equal to "transitional". I have read the documentation, but have not been able to solve this problem, and it should be pretty simple. So far, I tried with something like.

    variable var: XMLList = classInfo.variable. (the metadata. (@name! = "transitoire")) ;

    variable var: XMLList = classInfo.variable. (metadata.@name! = "transitional");

    But he returns all the nodes variable.

    "< name =" type com.sca.dataModel::PresentationDataEntity"base =" com.sca.dataModel::BaseEntity "isDynamic ="false"isFinal ="false"isStatic ="false">
    < extendsClass type="com.sca.dataModel::BaseEntity"/ >
    < extendsClass type = 'Object' / >
    < variable name = "subtitle" type = "string" >
    < name of metadata = "__go_to_definition_help" >
    < arg key = 'file' value="/Users/jonas/projects/SCA-CMS/src/com/sca/dataModel/PresentationDataEntity.as"/ >
    < arg key = "pos" value = "128" / >
    < / metadata >
    < / variable >
    < variable name = "id" type = "Number" >
    < name of metadata = "__go_to_definition_help" >
    < arg key = 'file' value="/Users/jonas/projects/SCA-CMS/src/com/sca/dataModel/BaseEntity.as"/ >
    < arg key = "pos" value = "153" / >
    < / metadata >
    < / variable >
    < variable name = "tableName" type = "String" >
    < name of metadata = "transitional" / >
    < name of metadata = "__go_to_definition_help" >
    < arg key = 'file' value="/Users/jonas/projects/SCA-CMS/src/com/sca/dataModel/BaseEntity.as"/ >
    < arg key = 'pos' value = '118' / >
    < / metadata >
    < / variable >
    < variable name = "db_SortAsc" type = "Boolean" >
    < name of metadata = "transitional" / >
    < name of metadata = "__go_to_definition_help" >
    < arg key = 'file' value="/Users/jonas/projects/SCA-CMS/src/com/sca/dataModel/BaseEntity.as"/ >
    < arg key = "pos" value = "281" / >
    < / metadata >
    < / variable >
    < variable name = "title" type = "String" >
    < name of metadata = "__go_to_definition_help" >
    < arg key = 'file' value="/Users/jonas/projects/SCA-CMS/src/com/sca/dataModel/PresentationDataEntity.as"/ >
    < arg key = "pos" value = "100" / >
    < / metadata >
    < / variable >
    < method name = "setData" declaredBy = "com.sca.dataModel::BaseEntity" returnType ="*" > "
    < parameter index = '1' type = 'Object' optional = "false" / >
    < name of metadata = "__go_to_definition_help" >
    < arg key = 'file' value="/Users/jonas/projects/SCA-CMS/src/com/sca/dataModel/BaseEntity.as"/ >
    < arg key = "pos" value = "330" / >
    < / metadata >
    < / method >
    < name of metadata = "__go_to_ctor_definition_help" >
    < arg key = 'file' value="/Users/jonas/projects/SCA-CMS/src/com/sca/dataModel/PresentationDataEntity.as"/ >
    < arg key = "pos" value = "167" / >
    < / metadata >
    < name of metadata = "__go_to_definition_help" >
    < arg key = 'file' value="/Users/jonas/projects/SCA-CMS/src/com/sca/dataModel/PresentationDataEntity.as"/ >
    < arg key = "pos" value = "42" / >
    < / metadata >
    < / type >

    Try classInfo.variable. ([email protected] (.indexOf("transient')) is

    (- 1).

  • Quality element derived from Master Collection Oracle based on Plans for the child?

    As an Oracle, we have a collection Plan and a Plan for the Collection. The child Map Collection contains many instances sample were out.

    Let's Say there were 5 samples for a number of batch (batch number as the Parent in Master Plan of collection). An element of the Collection take for example. Size. a observation of the sample.

    # Sample size.
    1 16
    2 16
    3 16
    4 32
    5 40

    So based on the example of the child, we would like to put the size of the collection in the level item Parent's maximum allowed size of all samples of the child.

    which in this case than the 16.

    Quality > configurations > relationships define/update the Parent child Plan

    Define a relationship that makes parentplan.samplesize = max (childplan.samplesize)

  • Insert the hyphen or a number to designate the child node

    I have a query that returns the parent node and the children of this one up to certain level. Like this:
    sort_order nodes
    00001 NOde1 - parent1
    0000100001 Node2 - child1of parent1
    000010000100001 Node3 - child1 Node2
    and so on.
    I want to format it like this :
    - Node1 - parent1
      -Node2 - child1 of parent1
       -Node3 - child of Node2
    -BNode1 -another parent
     -BNode2 - child of Bnode1
     -BNode3 - child of Bnode1
       -Bnode4 - child of Bnode3 
     
    How can I do this
    Thnx

    Hello

    OAF - dev wrote:
    Frank
    You spotted correctly.
    LENGTH (sort_order) = 7 for parent,
    LENGTH (sort_order) = 14 to a lower level,
    LENGTH (sort_order) = 21 for the lower level 2,
    LENGTH (sort_order) = 28 for the 3rd level,
    I did this:
    , LPAD (' ', (LENGTH (temp.sort_order) * 4 / 7)-4) | '-' || MSI. Segment1 AS indented_segment1

    He gets the hyphen at the front, but don't be indented?
    Thnx

    It works for me, in SQL * more. What are front-end do you use? Could it be stripping spaces? Just for the moment, try the padding with anything other than spaces (periods may) by the way of an argument 3rd to LPAD.
    I guess temp.sort_order is a VARCHAR2: is it? Display of its length.

    In other words, your select clause must have something like

    ,       LPAD ( ' '
              , ( LENGTH(temp.sort_order) * 4 / 7) - 4
              , '.'                                   -- For debugging
              ) || '-' || msi.segment1          AS indented_segment1
    ,     LENGTH (temp_sort_order)          AS len_sort_order     -- For debugging
    

    What is the result of these columns?

    It is always good to post a small example data (CREATE TABLE and only relevant columns, INSERT statements) and the results that you want from this data.

  • Add the new node to cluster oracle

    Hello
    I have a doubt regarding cluster approx.
    The current situation is oracle instances are running on 2 boxes unix say that U1 and U2
    Now if we include another U3 area in the cluster, is it totally black box for the application.
    My concern is that should make us changes in the application using the cluster.

    Thank you
    Arpit Narula

    Hello

    Background database servers are normally transparent to the applications, but could you let us know which app frontend you use...?

    Satya.

  • How to write a hierarchical query so that only the child nodes are displayed?

    Hi all

    I have a hierarchical query that I use in an area of tree demand APEX and there are nodes that have no children and I am trying to find a way to not display these nodes. Essentially if the user does not have to develop a lot of knots to know that nothing exists at the most detailed level.

    The data are based on the Oracle Fusion FND tables but for example purposes here is enough data to illustrate my question:


    create table APPL_TAXONOMY_HIERARCHY (SOURCE_MODULE_ID varchar2(30), TARGET_MODULE_ID varchar2(30));
    create table APPL_TAXONOMY_TL (module_id varchar2(30), description varchar2(100), user_module_name varchar2(30), language varchar2(5));
    create table APPL_TAXONOMY (MODULE_ID    varchar2(30),    MODULE_NAME    varchar2(30), MODULE_TYPE varchar2(10),    MODULE_KEY varchar2(30));
    create table TABLES (table_name varchar2(30), module_key varchar2(30));
    
    

    insert into APPL_TAXONOMY_TL values ('1', null, 'Oracle Fusion', 'US' );
    insert into APPL_TAXONOMY_TL values ('2', null, 'Financials', 'US' );
    insert into APPL_TAXONOMY_TL values ('3', null, 'Human Resources', 'US' );
    insert into APPL_TAXONOMY_TL values ('20', null, 'Accounts Payable', 'US' );
    insert into APPL_TAXONOMY_TL values ('10', null, 'General Ledger', 'US' );
    
    insert into APPL_TAXONOMY_HIERARCHY values ('1', 'DDDDDDDD');
    insert into APPL_TAXONOMY_HIERARCHY values ('2', '1');
    insert into APPL_TAXONOMY_HIERARCHY values ('3', '1');
    insert into APPL_TAXONOMY_HIERARCHY values ('4', '1');
    insert into APPL_TAXONOMY_HIERARCHY values ('10', '2');
    insert into APPL_TAXONOMY_HIERARCHY values ('20', '2');
    
    insert into APPL_TAXONOMY values ('1', 'Fusion', 'PROD', 'Fusion');
    insert into APPL_TAXONOMY values ('2', 'Financials', 'FAMILY', 'FIN');
    insert into APPL_TAXONOMY values ('10', 'GL', 'APP', 'GL');
    insert into APPL_TAXONOMY values ('3', 'Human Resources', 'FAMILY', 'HR');
    insert into APPL_TAXONOMY values ('20', 'AP', 'APP', 'AP');
    
    insert into tables values ('GL_JE_SOURCES_TL','GL');
    insert into tables values ('GL_JE_CATEGORIES','GL');
    

    My hierarchical query is as follows:

    with MODULES as
    (
    SELECT h.source_module_id, b.user_module_name, h.target_module_id
          FROM APPL_TAXONOMY_HIERARCHY H,
          APPL_TAXONOMY_TL B,
    APPL_TAXONOMY VL
    where H.source_module_id = b.module_id
    and b.module_id = vl.module_id
    and vl.module_type not in ('PAGE', 'LBA')
    UNION ALL
    select distinct table_name, table_name,  regexp_substr(table_name,'[^_]+',1,1) 
    from TABLES --needed as a link between TABLES and APPL_TAXONOMY
    union all
    select module_key as source_module_id, module_name as user_module_name, module_id as target_module_id  from appl_taxonomy VL where VL.module_type = 'APP')
    SELECT  case when connect_by_isleaf = 1 then 0
                when level = 1             then 1
                else                           -1
           end as status,
    LEVEL,
    user_module_name as title,
    null as icon,
    ltrim(user_module_name, ' ') as value,
    null as tooltip,
    null as link
          FROM MODULES
          START WITH source_module_id = '1'
          CONNECT BY PRIOR source_module_id = target_module_id
    ORDER SIBLINGS BY user_module_name;
    

    In Oracle APEX, this gives a tree with the appropriate data, you can see here:

    https://Apex.Oracle.com/pls/Apex/f?p=32581:29 (username: guest, pw: app_1000);

    The SQL of the query results are:

    STATUSTITLE LEVELVALUE

    ---------- ---------- ------------------------------ ------------------------------

    11 oracle FusionOracle Fusion
    -12 financial tablesFinancials
    -13 accounts payableAccounts payable
    04 APAP
    -1General Accounting 3General Accounting
    -14 GLGL
    05 GL_JE_CATEGORIESGL_JE_CATEGORIES
    05 GL_JE_SOURCES_TLGL_JE_SOURCES_TL
    02 human resourcesHuman resources

    The lowest level is the name of the table to level 5. HR is not any level under level 2, in the same way, "AP" (level 4) has nothing below, i.e. no level 5 and that's why I don't want to show these nodes. Is this possible with the above query?

    Thanks in advance for your suggestions!

    John

    Hello

    The following query will include only the nodes of level = 5 and their ancestors (or descendants):

    WITH modules LIKE

    (

    SELECT h.source_module_id

    b.user_module_name AS the title

    h.target_module_id

    To appl_taxonomy_hierarchy:

    appl_taxonomy_tl b

    appl_taxonomy vl

    WHERE h.source_module_id = b.module_id

    AND b.module_id = vl.module_id

    AND vl.module_type NOT IN ('PAGE', "LBA")

    UNION ALL

    SELECT DISTINCT

    table-name

    table_name

    , REGEXP_SUBSTR (table_name, ' [^ _] +')

    From the tables - required as a link between the TABLES and APPL_TAXONOMY

    UNION ALL

    SELECT module_key AS source_module_id

    AS user_module_name module_name

    module_id AS target_module_id

    Of appl_taxonomy vl

    WHERE vl.module_type = 'APP '.

    )

    connect_by_results AS

    (

    SELECT THE CHECK BOX

    WHEN CONNECT_BY_ISLEAF = 1 THEN 0

    WHEN LEVEL = 1 THEN 1

    OF ANOTHER-1

    The END as status

    LEVEL AS lvl

    title

    -, NULL AS icon

    , LTRIM (title, "") AS the value

    -, NULL as ToolTip

    -, Link AS NULL

    source_module_id

    SYS_CONNECT_BY_PATH (source_module_id - or something unique

    , ' ~' - or anything else that may occur in the unique key

    ) || ' ~' AS the path

    ROWNUM AS sort_key

    Modules

    START WITH source_module_id = '1'

    CONNECT BY PRIOR Source_module_id = target_module_id

    Brothers and SŒURS of ORDER BY title

    )

    SELECT the status, lvl, title, value

    -, icon, tooltip, link

    OF connect_by_results m

    WHEN THERE IS)

    SELECT 1

    OF connect_by_results

    WHERE the lvl = 5

    AND the path AS ' % ~' | m.source_module_id

    || '~%'

    )

    ORDER BY sort_key

    ;

    You may notice that subqueries modules and the connect_by_results are essentially what you've posted originally.  What was the main request is now called connect_by_results, and it has a couple of additional columns that are necessary in the new main request or the EXISTS subquery.

    However, I am suspicious of the 'magic number' 5.  Could you have a situation where the sheets you are interested in can be a different levels (for example, some level = 5 and then some, into another branch of the tree, at the LEVEL = 6, or 7 or 4)?  If so, post an example.  You have need of a Query of Yo-Yo, where you do a bottom-up CONNECT BY query to get the universe of interest, and then make a descendant CONNECT BY query on this set of results.

  • Get children nodes and only the child nodes of a tree?

    Hi all

    Relatively simple table
    create table replaced_parts
    (
     old_part_number varchar(7),
     replaced_part_number varchar(7),
     updated_date date
    );
    
    insert into Replaced_parts values('AAAAA/1', 'BBBBB/1', '2012-Feb-16');
    insert into Replaced_parts values('BBBBB/1', 'FFFFF/1', '2012-Feb-23');
    insert into Replaced_parts values('YYYYY/3', 'ZZZZZ/3', '2012-Mar-17');
    insert into Replaced_parts values('FFFFF/1', 'LLLLL/1', '2012-Mar-18');
    insert into Replaced_parts values('LLLLL/1', 'HHHHH/1', '2012-Mar-19');
    The question is how can I issue a select using the "AAAAA/1 ' and get the result ' HHHHH/1 ' «»
    i.e. (A-> B, B-> F, F-> L, L-> H)
    Select using the "YYYYY/3 ' get ' ZZZZZ/3 ' (y-> Z)?

    It would be really nice if I could also get my original value, say, "CARTER/1". "If there is no entry
    for "CARTER/1 ' in the replaced_parts table (perhaps NVL?).»

    I googled and tried different combinations of CONNECT BY PRIOR, ISLEAF... & c but
    beat me my head on a brick wall at the present time.

    TIA,

    Paul...

    Hello

    Once again, thanks for posting the CREATE TABLE and INSERT statements.
    Once again, please post instructions that work. You're still trying to put VARCHAR2s in a DATE column (replaced_parts.updated_dates). There is no CREATE TABLE Or REPLACE Oracle statement.
    The query you posted reference order_parts.user_number, but does not include the sample data in this column.
    Be sure to post the results desired from the given sample data.

    Assuming that there is no branching at replaced_parts (in other words, each parent has only 1 child), you could do something like this:

    SELECT O.User_Number,
           Op.Order_Number,
           Op.Part_Number,
           P.description,
           P.price,
           Op.Quantity_Ordered,
           O.Order_Date
    ,      (               -- Begin added code
               SELECT  replaced_part_number
            FROM        replaced_parts
            WHERE   CONNECT_BY_ISLEAF     = 1
            START WITH     old_part_number     = op.part_number
            CONNECT BY     old_part_number     = PRIOR replaced_part_number
           )
    FROM
           Order_Table O,
           Order_Parts Op,
           Parts         P
    WHERE
           O.User_Number  = Op.User_Number
    AND    O.Order_Number = Op.Order_Number
    AND    Op.Part_Number = P.Part_Number    --  <----- sub-select changing the part no. if necessary should go here
    ;
    

    No matter that there is no branching, you can do something like this:

    WITH     old_parts   AS
    (
         SELECT O.User_Number,
                Op.Order_Number,
                Op.Part_Number,
                P.description,
                       P.price,
                       Op.Quantity_Ordered,
                       O.Order_Date
            FROM
                       Order_Table O,
                       Order_Parts Op,
                       Parts         P
         WHERE
                       O.User_Number  = Op.User_Number
         AND    O.Order_Number = Op.Order_Number
         AND    Op.Part_Number = P.Part_Number
    )
    ,     new_parts     AS
    (
               SELECT  CONNECT_BY_ROOT old_part_number     AS orig_part_number
            ,        replaced_part_number
            FROM        replaced_parts
            WHERE   CONNECT_BY_ISLEAF     = 1
            START WITH     old_part_number     IN (
                                        SELECT  part_number
                                    FROM    old_parts
                                    )
            CONNECT BY     old_part_number     = PRIOR replaced_part_number
    )
    SELECT       o.*
    ,       n.replaced_part_number
    FROM           old_parts  o
    LEFT OUTER JOIN  new_parts  n  ON  o.part_number  = n.orig_part_number
    ;
    
  • The child node listening event of the parent

    Is this possible? and how?

    parent.addEventListener ("someEvent", functionInChildComponet);

    parentDocument, parentApplication, or application or...

    Tracy

Maybe you are looking for