URGENT *** Hierarchical Tree in Forms 9i *** URGENT

Hello everybody,
for my company I need to build a hierarchical tree item, that will display static data over three levels. Let's say: departments, employees and employee projects.
How do I fill the Item?
When do I fill the Item?
Where do I fill the Item?
What are the elements of the SQL query, that fills the hierarchical tree?
Any help will be appreciated
[email protected]

Note:210663.1 helped a bit.
I used the database column as the third element in the select part and put NULL as the fifth element. Then it worked.
Now I am looking for the way to add the employees, when the user selects / activates a department node.

Similar Messages

  • Hierarchal tree in FORMS

    Hi,
    I have a hierarchal tree table that I want to represent using forms (insert and update data in the tree table).
    Are there any LINKS or documentation that can help me with my little project :-)
    Thanks,
    Marc.

    The help file has a fairly detailed description of how to manipulate the tree control.
    Provided you have a table that can do this I would do "connect by prior" and "start with" SQL statement and use the pseudo column called "level" to determine when to create a new sub tree and when to end it.

  • Creating a Hierarchical Tree in Forma 6i

    Hi Gurus,
    We are using forms 6i and oracle 9i. In oracle forms i have one control block and another control block. When we click on one column repname ,the other control block displays the
    corresponding info for the sales rep name. eg. Lets say i pick John the salesrep in the other
    control block it displays its code,geography region etc.
    I want to create a hierarchical tree in the other block where it is displaying the salesrep info.
    So i want when i click on the sales rep name(the other control block measure)
    then it should the code,geography region etc in the form of hierarchical tree in the other control
    block. If the sales rep name is not clicked then the control block having the salesrep info should be hidden.
    I would appreciate your help.
    Thanks,
    PSO

    place your treeitem in the layout. The treeitem has to the only item in the block and property "Single record" has to be true.
    To populate your tree with data you can either
    - use a query to populate a treeitem have a look at this thread Tree Menu
    - use the Ftree.Add_Tree_Node built-in and program your own logic.

  • Hierarchical trees in forms

    in my oracle forms application i'm working with hierarchical
    trees; every time the tree displays all the nodes are expanded,
    but i want all of them to be collapsed, i tried to set the
    properties of the tree with ftree.collapsed_node, but i only got
    an error message that i didn't select any node.
    Can somebody help me?
    null

    Dear Friend,
    Try this piece of code this will solve your problem
    tree_item:=find_item('your tree item');
    find_node:=ftree.find_tree_node(tree_item,'your_Node_name',
    ftree.find_next,ftree.node_label,
    ftree.root_node,ftree.root_node);
    ftree.SET_TREE_NODE_PROPERTY
    (tree_item,find_node,ftree.node_state,ftree.collapsed_node);
    do the neccessary changes and apply
    bye
    Vishnu Vadla
    null

  • How to call forms using Hierarchical Tree in Forms 10g?

    I know how to call forms from menu that attached to a top form.
    I would like to call forms using Hierarchical Tree. Does any one know how where I can find some instructions on using Hierarcical Tree to call other forms? Any discussion is welcome. Thanks.

    Thanks to Francois.
    The exampe with clear instructions and I can build tree that calls forms now.
    I add a OPEN_FORM statement in WHEN-TREE-NODE-ACTIVATED trigger
    Declare
         LN$I Pls_integer ;
    Begin     
    :Ctrl.Node_Activated := Ftree.Get_Tree_Node_Property('BL_TREE.MENU', :SYSTEM.TRIGGER_NODE, Ftree.NODE_VALUE) ;
    If :Ctrl.Node_Activated IS NOT NULL Then
         Set_Alert_Property( 'AL_CALL_FORM', ALERT_MESSAGE_TEXT, 'Calling module : ' || :Ctrl.Node_Activated ) ;
         LN$I := Show_Alert( 'AL_CALL_FORM' ) ;
         open_form(:Ctrl.Node_Activated);
    End if ;
    End ;
    Or call physical form path by:
         open_form('c:\tree\'||:Ctrl.Node_Activated ||'.fmx');
    I enter the VALUE of MENU as the Form fmx name and it works very well.
    Thanks so much.

  • *** URGENT *** Hierarchical Tree *** URGENT ***

    Hi,
    following situation:
    I have a tree item (ht) in a block TB_FRM_NAME within a help form. This tree is filled with the Module Names within the entire application.
    I fill this in the WNFI:
    Fpr_Fill_Tree_Item
    ( 'TB_FRM_NAME.HT' -- pi_tree_item_name
    , 'rgp_fwe' -- pi_record_group_name
    , 'SELECT b_fu_id , ' -- pi_sql_statement
    ||'level , '
    ||'bemerkung, '
    ||' NULL, '
    ||' NULL '
    ||'FROM b_funk '
    ||'ORDER BY bemerkung
    The Content of the forms-procedure is:
    PROCEDURE Fpr_Fill_Tree_Item
    -- In-Parameter
    ( pi_tree_item_name IN VARCHAR2
    , pi_record_group_name IN VARCHAR2
    , pi_sql_statement IN VARCHAR2
    ) IS
    -- Variablendeklaration
    v_tree_item Item; -- für das Baumverzeichnis
    v_rgp_id RecordGroup;
    BEGIN
    -- Initialisierung der Variable, Itemname holen
    v_tree_item := Find_Item (pi_tree_item_name);
    v_rgp_id := Find_Group (pi_record_group_name);
    IF NOT Id_Null (v_rgp_id) THEN
         -- Record Group existiert bereits, also löschen
         Delete_Group (pi_record_group_name);
    END IF;
    -- SQL Statement für die Record Group (Bedeutungen)
    -- 1. Element Initial State
    -- 2. Element Depth
    -- 3. Element Label
    -- 4. Element Icon
    -- 5. Element Data -- when I enter Column name here
    -- filling the tree doesn't work!
    v_rgp_id := Create_Group_From_Query
    ( pi_record_group_name
    , pi_sql_statement
    -- Wenn die Record Group erstellt werden kann, ...
    IF Populate_Group (v_rgp_id) = 0 THEN -- Fehlerlos
    -- Record Group mit Tree verknüpfen
    Ftree.Set_Tree_Property
    ( v_tree_item
    , Ftree.Record_Group
    , pi_record_group_name
    END IF;
    END;
    After filling I want to add the names of the tab_canvas pages, when the user clicks one of the Modules in the application.
    To test this I added following code in the WTNS Trigger:
    -- Hier muss die nächste Ebene des Baumverzeichnisses gefüllt werden
    DECLARE
    v_node Ftree.Node;
    v_tree_id Item;
    v_tree_level NUMBER;
    v_tree_label VARCHAR2 (30);
    v_tree_value VARCHAR2 (30);
    BEGIN
    v_tree_id := Find_Item ('TB_FRM_NAME.HT');
    v_tree_value := Ftree.Get_Tree_Node_Property
    ( v_tree_id
    , :SYSTEM.TRIGGER_NODE
    , Ftree.Node_Value
    v_tree_label := Ftree.Get_Tree_node_Property
    ( v_Tree_id
    , :SYSTEM.TRIGGER_NODE
    , Ftree.Node_Label
    v_tree_level := Ftree.Get_Tree_node_Property
    ( v_Tree_id
    , :SYSTEM.TRIGGER_NODE
    , Ftree.Node_Depth
    IF v_tree_level = 1 THEN
    v_node := Ftree.Add_Tree_Node
    ( v_tree_id
    , :SYSTEM.TRIGGER_NODE
    , Ftree.Sibling_offset
    , Ftree.Next_Node
    , Ftree.EXPANDED_NODE
    , 'M'
    , NULL
    , 'M'
    v_node := Ftree.Add_Tree_Node
    ( v_tree_id
    , v_node
    , Ftree.Parent_Offset
    , 1
    , Ftree.LEAF_NODE
    , 'SUB'
    , NULL
    , 'SUB'
    END IF;
    END;
    Result of this is, that the newly added node is placed at the first level of the tree. I don't want this! I would like to know what to do, so the newly added node is being shown at the second level.
    Result
    +-module1
    |-module2
    |-module3
    Then the user clicks on module2 and the result is
    +-module1
    |-module2
    --M
    ||-SELECT bemerkung FROM b_kat*
    |-module3
    Desired Result
    +-module1
    --module2
    ||-tab_page1
    ||-tab_page2
    ||-tab_page3
    |-module3
    *) Here I want the contents of the column to be displayed and NOT THE select statement.
    Thank you for any help

    Hi,
    I am shalauddin from bangladesh,
    My e-mail address is [email protected]
    mail me hear then I will give you a attachment articals on tree that will help u and solv your problem.
    Regards,
    shalauddin.

  • Hierarchical tree in forms 10g

    dear member.
    i am a beginner. and want to know about that how to make hierarchical form
    i am using developer suit 10g.
    thanks
    mustafa
    lahore,pakistan

    Mustafa,
    the way u have marked the node_id and parent_node_id in the two tables, it is done at form level. or what... this is a little confusing to me, i have to apply that ht form at other schema.Yes, I create Record Group that populates the HT in the When-New-Form-Instance (WNFI) trigger. You can populate an HT from just about anywhere, but I use the WNFI to ensure the tree is populated when the form loads.
    To add a "Grandchild" node to your tree, you simply need to modify the WNFI trigger and add a Loop for these nodes. Using your data as an example, the code in the WNFI would look something like this (not tested):
    DECLARE
       CURSOR c_comp IS
          SELEC T compcode, name
            FRO M company;
       CURSOR c_div (p_comp NUMBER) IS
          SELEC T div_id, div_name, dept_id
            FRO M s_div
          WHER E compcode = p_comp;
       CURSOR c_dept (IS
          SELEC T dept_id, dept_name
           FRO M s_dept
         WHER E dept_id = p_dept;
       n_level NUMBER := 1;
       n_row NUMBER := 1;
       rg_id  RECORDGROUP;
       node Ftree.Node;
    BEGIN
       Tree_Control.v_item_name := 'MY_TREE_DATA.MY_TREE';
       rg_id := Tree_Control.Create_RG;
       <<parent>>
       FOR r_comp IN c_comp LOOP
          -- Add Parent Company
          Tree_Control.ADD_RG_ROW(rg_id, ftree.collapsed_node, n_row,
                  n_level, r_comp.name, null, r_comp.compcode);
          n_row := n_row + 1;
          n_level := n_level + 1;
          -- Add any child Department records
          <<child>>
          FOR r_div IN c_div(r_comp.compcode) LOOP
             Tree_Control.ADD_RG_ROW(rg_id, ftree.collapsed_node, n_row,
                  n_level, r_div.div_name, null, r_div.div_id);
             n_row := n_row+1;
             -- Now, add any Grandchildren
            <<grandchild>>
            FOR r_dept IN c_dept(r_div.dept_id) LOOP
               Tree_Control.ADD_RG_ROW(rg_id, ftree.collapsed_node, n_row,
                   n_level, r_dept.dept_name, null, r_dept.dept_id);
            END LOOP grandchild;
          END LOOP child;
       END LOOP parent;
       ftree.Add_Tree_Data(Tree_Control.v_item_name, ftree.ROOT_NODE,
                       ftree.PARENT_OFFSET, ftree.LAST_CHILD,
                       ftree.RECORD_GROUD, rg_id);
    END;You will still need to modify the Create_RG function in the Tree_Control package to support the above changes, but this code sample should get you started.
    Craig...

  • Problem creating a hierarchical tree in forms builder[issue with the query]

    Hi all,
    I have 2 tables.
    box (box_id, box_name)
    item(item_id, item_name, box_id)
    In a box there are several items.
    I want to create a hierachical tree to display items that are present in each box.
    LIKE:
    |---BOX1
    | |----ITEM 1
    | |----ITEM 2
    |
    |---BOX2
    | |----ITEM 1
    | |----ITEM 2
    Currently i am trying this query:
    SELECT -1 state, box_name, 'icon' icon, box_id val
    from box b, item i;
    I don't know what value to put for level, i don't know how to code the 'connect by prior' part.
    Could you please advise me?
    Michaël.
    PS. Then i will eventually use this query in forms builder.

    Hi MichaelR
    i get the FRM - 47321 error in forms builder ..
    Hence In order to populate a tree, the Select order must retrieve 5 columns:
    STATUS, LEVEL, LABEL, ICON, VALUE u should notice this orders in ur Query this will solve the error and pls notice that the...
    My advice is to use the On Line help in ur forms builder to help u in this ...
    Initial state : number
    Node tree depth : number
    Label for the node : varchar2
    Icon for the node : varchar2
    Data : varchar2This should be in WHEN-NEW-FORM-INSTANCE-trigger in order to populate ur tree...
    another thing why don't u think of building ur tree as i did here in the following example...Pls have a look here ....
    Hope this helps...
    Regards,
    Amatu Allah.

  • Forms 6 hierarchical Tree

    I would like to Know concept of Hierarchical Tree of forms 6i. What query should be written in the record group to populate the tree and how to implement hierarchical tree to make the form act like Windows Explorer .
    Thank You.

    Read the documentation. Here is a sample query to load the record group.
    PROCEDURE prc_populate_record_group
    IS
    CURSOR g IS
    SELECT groupnum,
    groupnm
    FROM merch_group
    ORDER BY groupnm;
    CURSOR c (l_groupnum NUMBER) IS
    SELECT categorynum,
    categorynm
    FROM merch_group_category
    WHERE groupnum = l_groupnum
    ORDER BY categorynm;
    i NUMBER;
    l_rg_id RECORDGROUP;
    l_init_state GROUPCOLUMN;
    l_level GROUPCOLUMN;
    l_label GROUPCOLUMN;
    l_icon GROUPCOLUMN;
    l_value GROUPCOLUMN;
    l_node ftree.node;
    l_next_node ftree.node;
    l_tree_item ITEM;
    BEGIN
    l_rg_id := FIND_GROUP('PRC_GROUP_CAT');
    IF NOT ID_NULL(l_rg_id)
    THEN
    DELETE_GROUP(l_rg_id);
    END IF;
    l_rg_id := CREATE_GROUP('PRC_GROUP_CAT');
    l_init_state := ADD_GROUP_COLUMN(l_rg_id, 'init_state', NUMBER_COLUMN);
    l_level := ADD_GROUP_COLUMN(l_rg_id, 'level', NUMBER_COLUMN);
    l_label := ADD_GROUP_COLUMN(l_rg_id, 'label', CHAR_COLUMN, 40);
    l_icon := ADD_GROUP_COLUMN(l_rg_id, 'icon', CHAR_COLUMN, 20);
    l_value := ADD_GROUP_COLUMN(l_rg_id, 'value', CHAR_COLUMN, 40);
    i := 1;
    FOR g_rec IN g
    LOOP
    ADD_GROUP_ROW (l_rg_id, i);
    SET_GROUP_NUMBER_CELL(l_init_state, i, -1);
    SET_GROUP_NUMBER_CELL(l_level, i, 1);
    SET_GROUP_CHAR_CELL(l_label, i, g_rec.groupnm&#0124; &#0124;' - '&#0124; &#0124;g_rec.groupnum);
    SET_GROUP_CHAR_CELL(l_icon, i, NULL);
    SET_GROUP_CHAR_CELL(l_value, i, g_rec.groupnum);
    i := i + 1;
    FOR c_rec IN c (g_rec.groupnum)
    LOOP
    ADD_GROUP_ROW (l_rg_id, i);
    SET_GROUP_NUMBER_CELL(l_init_state, i, -1);
    SET_GROUP_NUMBER_CELL(l_level, i, 3);
    SET_GROUP_CHAR_CELL(l_label, i, c_rec.categorynm&#0124; &#0124;' - '&#0124; &#0124;c_rec.categorynum);
    SET_GROUP_CHAR_CELL(l_icon, i, NULL);
    SET_GROUP_CHAR_CELL(l_value, i, c_rec.categorynum);
    i := i + 1;
    END LOOP;
    END LOOP;
    --Find the tree
    l_tree_item := find_item('CONTROL.TREE4');
    -- Assign record group to item causing the data to display
    ftree.set_tree_property(l_tree_item, ftree.record_group, l_rg_id);
    -- Find the root node of the tree
    l_node := ftree.find_tree_node(l_tree_item, '');
    END;
    null

  • Finding proper help on Hierarchical Trees

    Have spent a couple of hours trying to navigate the sprawling website of oracle.com with the purpose finding and then downloading the appropriate help file. I downloaded
    Oracle9i Developer Suite Release 2 Documentation Library
    from
    http://www.oracle.com/technology/documentation/ids.html
    Its about 130Mb, installed it, but could i find comprehensive documentation on using Forms 9i (in particular Hierarchical Trees) no, but everything else it seemed yes. The original doc that pre-installed with the 9i DS 'online help' is reasonably helpful but like some others on this forum I could not find proper help on how to use Hierarchical Trees all i could find was few descriptive portions of text and believe me i have looked.
    Others have said they found examples of Hierarchical Trees usage i can only assume they are using 10g. So this is a desperate plea to you. Can you point me to an online resource that deals with Hierarchical Trees in Forms 9i (intro, usage, examples, etc). If you can i would deeply appreciate it.
    Mr Frustrated :)

    Hi,
    You have a lot of sample With the Forms Help.
    If you search in the index with "htree."
    The command hierarchical tree complete list appear.
    L.

  • Hierarchical trees

    Dear Sir,
    I need to know whether I can use hierarchical trees in Forms 6.0. If yes, please send me the instruction to do.
    And I need to know Client-Server architecture Application deployment.
    Thanks in Advance.

    This forum is for feedback about OTN services and content. Please post your question in the Oracle Forms forum:
    Forms

  • Colourful Hierarchical Tree

    Hi,
    This is the first thread am posting. I searched ur discussions for "How to show the hierarchical tree in forms 10g with different colours and in different fonts weigth for different nodes". But i found nothing.
    Hopefully looking forward for your replies.

    You should use a less specific search string if you don't find anything first time but in this case it won't have helped you.
    You can set an icon for each node in the tree, which might be an acceptable alternative to writing lots of java.
    The icon can be set as a property
    http://www.oracle.com/webapps/online-help/forms/10g/topics/f1_help/builts/set_tree_node_property_built_in.html?tp=true
    or it can be built into the select statement that creates the tree (if your tree is query-driven).

  • Compiling error in Hierarchical Tree !!!!! Urgent attention!!!

    I have made the Hierarchical Tree as described in the resuable demo help as is but when ever i try to compile the form i gets error on the navigator."anything!". I guess the forms are not able to find the navigator package. I have attached the navigator.pll. I think there is nothing mroe to attach to a form
    Till now i have searched every documentation on the net and the files ships wiht DEV 6.0.5.2. But not ablet o find any thing regarding the installation of navigator package :( Is there any one can tell me how u remover the compiling error from the form which is dur to the navigator package!!!!
    null

    If you are using DEV 6.0.5.2 you should use the FTREE built-in package. Look under the Built-In package node. The Navigator.pll was a demo used in Forms4.5 before there was a hierarchial tree item type.
    Thanks,
    Candace Stover
    Forms Product Management

  • Can i have a check box in the hierarchical tree in the icons place, urgent!!! please

    Hi,
    I'am working on the Hierarchical Tree structure which should have three levels, I need to have a check box in the place of the icon & if i select a node that node & the child nodes should get selected.
    After this when i say move selected ( i'am trying to use picklist class also) the entire checked tree has to move to the display area to the right & should display as tree structure & after this if i save then the checked records which are moved to another text area should get saved!!
    How to achieve this? I have the tree structure ready but the check box part is the worrying factor! & then moving the checked records to the right using picklist class is the second problem & finally saving records to database.
    Any help in this regard will be deeply appreciated:)
    If check box is not possible then i will have to look at other methods, will the tree structure allow checkboxes????
    Thanks
    Mahesh

    No the tree will not allow checkboxes

  • Add checkbox on the nodes of Hierarchical tree in oracle forms 9i

    Hi,
    I am working on oracle forms 9i.I have to add checkbox at the place of node(+/-) in Hierarchical tree so,
    that user can select or deselect the Tree.That can do in oracle forms but how i don't know.
    can anybody help me.....
    Regards,
    Hemant

    You can't change this aspect of the Tree Control in Oracle Forms using built-in functionality. You might be able to extend the Tree Control using Java, but you have to do this yourself. : (
    Craig...

Maybe you are looking for

  • Multiple users on Mail

    Hi - this is probably a silly question. My wife and I share our mac. when we set it up we did not set up multiple accounts as was too complicated to share photos in iphoto, addresses etc. would like though to be able to "split" our use of mail. can e

  • I-pod not recognized...cannot even restore.

    I ran the i-pod updater to restore the problem but the thing just freezes on instalizing.....i can't even restore my i-pod......some one please help me!!!!!!!!!!!!!

  • Can't find drivers for WIN XP - Satellite L300D-10U

    Hi! I am really having a hard time finding drivers for xp for my laptop. I downgraded it from Vista and cant find it anywhere I looked. I found only the Ethernet driver. The drivers cant be found on the official web site. (at least i cant) Would anyo

  • Help - Multiple same-class functions

    I've been looking around the internet for a couple of days now trying to find an answer to this question. My search has been fruitless, so I've resorted to posting on a forum. Hopefully someone here will be able to give me a clue... I'm currently wor

  • Client Strategy questions with BPS in mind

    We are implementing BW and BPS. The system landscape in my project has been planned to have different client numbers and different logical systems for each environment for BW and Source Systems (Dev, Quality and Production). With BPS I am foreseeing