3 Replies Latest reply on Aug 23, 2009 3:04 PM by comment_1

    clients and appomtments

    fruquis

      Title

      clients and appomtments

      Post

      I have a db with table "clients" and a related table  in a portal "appointments".

      In the table appointments I have a field "attended by" :Name 

      Now I would like to find out:

      How many times does a client come back if he is attended by "Name"  at the first visit.

       

      I think I need a calculation field: getfield "attended by" first row  of appointments

      and a calculation field "Count appointments"

       

      I am stuck

       

      Gerrit 

       

       

        • 1. Re: clients and appomtments
          comment_1
            

          You could produce a report from the Clients table, summarized by Appointments::AttendedBy. A calculation field in the Clients table =

           

          Count (  Appointments::AttendedBy )

           

          will tell you how many appointments each client had (you can count any field in Appointments that cannot be empty).

           

           

          You could also add a summary field to average the count, and remove the body part from the report entirely.

          • 2. Re: clients and appomtments
            fruquis
              

            thanks , but i don't get it.

             

            You said:

             

             1)you could produce a report from the Clients table, summarized by Appointments::AttendedBy 

             

             

            Appointments::AttendedBy is not a summary field,   it is a text field  in table "appointments"

             

             

            2) 

             

             A calculation field in the Clients table =

             

            Count (  Appointments::AttendedBy )

             

            will tell you how many appointments each client had (you can count any field in Appointments that cannot be empty).

             

            I did that no problem 

             

            3) You could also add a summary field to average the count, and remove the body part from the report entirely.

             

            How do I avoid calculation each time I enter a new "appointments rceord"

             

             

            Thanks again 

             

            • 3. Re: clients and appomtments
              comment_1
                

              fruquis wrote:
              Appointments::AttendedBy is not a summary field,   it is a text field  in table "appointments"

              Yes, I am aware of that. The suggestion is to place a sub-summary (when sorted by: Appointments::AttendedBy) part on the layout. Thus, when you sort by this field, it will group your clients by the person who attended them at their first appointment.