1 Reply Latest reply on Feb 7, 2012 6:01 PM by Shay Shmeltzer-Oracle

    How to create dvt:pieGraph with tabularData?

    Hozy-Oracle
      Hi,

      I'm trying to build dvt:pieGraph with tabularData; I'm not sure what datatype should the method call return? List/Hash ?

      I tried returning a List that contain single dimensional objects of size 3 (dept,dept,empCount), however the pie only prints the first object value.

      Thanks for the help.
      <dvt:pieGraph tabularData="#{viewScope.my_model.pieDataDeptEmp}" subType="PIE"  id="pieDeptEmp">
      public List<Object[]> getPieDataDeptEmp()
      {
        List<Object[]> pieDataDeptEmp= new ArrayList<Object[]>();
      
        Object[] row1 = new Object[3];
         rowItems[0]="HR";
         rowItems[1]="HR";
         rowItems[2]=new Integer(7);                    
         pieDataDeptEmp.add(row1); 
      
        Object[] row2 = new Object[3];
         rowItems[0]="Finance";
         rowItems[1]="Finance";
         rowItems[2]= new Integer(40);                    
         pieDataDeptEmp.add(row2);
      
        return pieDataDeptEmp;  
      }