Link to home
Start Free TrialLog in
Avatar of fyzalkabu
fyzalkabu

asked on

Adding data to a Hierarchical tree

i am having a tree with nodes as A-Z. i need to add data to these nodes from another table such that node A is having data as.. names of all the employees starting with alphabet 'A'..etc
i am using a procedure to retreive the data.
PROCEDURE proc_add_tree_data(str char) IS
BEGIN
 
 declare
  htree         ITEM;            
CURSOR cur_tree_query IS
   select distinct emp_first_name
         from emp_info_hdr
         where emp_first_name like str||'%';
         ename emp_info_hdr.emp_first_name%type;
        begin
              htree := Find_Item('BLOCK_TREE.HTREE');
              open cur_tree_query;
         LOOP
               fetch cur_tree_query into ename;
               Ftree.Add_Tree_Data(htree,
               Ftree.ROOT_NODE,
               Ftree.PARENT_OFFSET,
               Ftree.LAST_CHILD,
               Ftree.QUERY_TEXT,
               ename);
         
               exit when cur_tree_query%notfound;
         end loop;
         close cur_tree_query;
          
         END ;
 
END;

but this cursor is giving me error...invalid query for hierarchical tree.
Avatar of Helena Marková
Helena Marková
Flag of Slovakia image

I see that this procedure is used in Forms.
There is no "ename" there.
Oh sorry, now I see "ename".
ASKER CERTIFIED SOLUTION
Avatar of Helena Marková
Helena Marková
Flag of Slovakia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial