2 Replies Latest reply on May 18, 2016 1:38 AM by Atefe

    Automatic Calculation

    Atefe

      Hello FM Experts!

       

      I have started to develope a small FM database that keeps the data of patients of a hospital and different kinds of tests that they should do.
      for easy understanding, I have attached some pictures.
      In one table should be defined for each test, which patients have been examined. (plz see patients and tests pic).
      In another hand, different combinations of "done or not-done tests", make different type of Lists (list num 1, list num 2,.....). Therefore I should create a seperate table for keeping these infos.  (plz see test and lists pic).
      Finally I need a table ( layout) somehow as a combination of 2 previous tables.   (plz see connection pic).
      In this  layout for each patient,  should be automatically defined whether this patient has or has not done these tests. (with help of patients and tests table)
      After that according to the combination of the tests (that this paitient has or has not done), should the list number automatically be identified .(with help of  test and lists table ).

      Does anyone have a idea, how can I do these 2 automatic process with help of calculations? Thanks in advance!

       

      PS. the real tests and lists and patients are so much more that what I have written as an example! :))
      Best regards,
      Atefe

        • 1. Re: Automatic Calculation
          erolst

          The standard approach to this is: create …

           

          • a table Examination

          • a table Test

          • a table ExaminationTest

           

          That's the template from which you set up the actual tests.

           

          For that, you need

          • a table PatientTest

          • a table PatientExamination

           

          All this is combined as

           

          Patient  --< PatientExamination --< PatientTest >-- Test --< ExaminationTest >--Examination

           

          Now you need scripts that:

           

          • let you select an Examination (or several) from all Examinations

          • then create a PatientExamination record (or several) for the current patient and the selected examination(s)

          • find the Tests that belong to the Examination(s) as per ExaminationTest

          • copy them into PatientTest and relate them to the new PatientExamination record(s)

           

          These scripts can be a bit complex, but not really complicated.

           

          If you imagine the above template structure as a folder of paper-based questionnaires, then you just performed the equivalent of taking one (or more) out, putting it/them into a photocopier, creating a copy / copies and personalizing it / them with a patients name. There is your checklist.

           

          Now you can simply compare the number (count) of all related records (for the patient in toto, or per examination) in each table with the number of completed related records.

          • 2. Re: Automatic Calculation
            Atefe

            Thank you Erolst for your answer,
            Somethings are a little confusing for me! You say I should create both  "test" and "examination" tables? what do you mean of that? Actually they have the same meaning for me!

            Maybe you mean "List" ? right?

             

            And after that, what does do exactlly this script? I did not get it

             

            BR
            Atefe