2 Replies Latest reply on Mar 17, 2013 3:45 PM by cgallardo

    Pie Charts

    cgallardo

      Hi,

      I am trying to generate a pie chart of activities performed on any given day by different positions/role (i.e engineer, senior engineer, junior engineer, etc)

      The working day is divided into equal intervals of 30 minutes and is presented in a prefilled portal (via a script).

      The position description is picked from a drop down box.

       

      positions.JPG

      Is the table design below the appropriate one or should I be using self joins? I did try self join but I could not get it to work either. As you can see the chart I am getting is displaying each entry as an individual entry instead of grouping together engineers, cleaners, etc.

       

      rships.JPGchart.JPG

        • 1. Re: Pie Charts
          Mike_Mitchell

          Hello, cgallardo.

           

          Your data structure is good. What you need is a couple more fields in the join table to make this work.

           

          You'll need an elapsed time field if you want to see the time spent on each position. That'll be End Time - Start Time. You also will need a summary field, maybe ElapsedTimeSum, that calculates the total of the elapsed time.

           

          Then, based your chart on the join table, found set, summarized groups of records. Sort the join table on Position. Make your Slice Data equal to the summary field. That should do you.

           

          HTH

           

          Mike

          • 2. Re: Pie Charts
            cgallardo

            Thanks Mike,

            I didn't need to use a join table after all but the key was in the creation of an extra field to summarize the Position count and then to sort the records appropriately.

            As the portal is prefilled with 20 minute slots i do not need a counter for the minutes I can just multiply each occurence by 20minutes if needed.

             

            Thanks for your fast reply.