5 Replies Latest reply on May 14, 2016 12:42 PM by beverly

    Saving Radio Button Values


      Hello there, from a newbie! I'm using FileMaker Pro for dental patient records &cutting to the chase:


      -I'm using one layout with 4 tabs of (Patient General Info, Medical History, Treament, Billing)

      -So far, i've created TWO (2) tables (1 for PatientInfo (including ID)) and 1 for Medical History (fields: ID, Anticoagulants, Diabetes, Smoking)


      Everything works fine for the 1st tab for Patients General Information due to just simple text-related input. Now I would like to have the Anticoagulants, Diabetes, Smoking as radio buttons with either "Yes" or "No" options.

      I converted them to radio buttons, and also (dunno if correct), i made a relationship between "ID" field of PatientInfo table and all of the 3 options of Medical History table. Thing is, that in Browse Mode i can select either Yes/No but my option is not saved for each patient (and generally NOT saved at all - with each click or changing records the value set is lost).


      Any help?!

        • 1. Re: Saving Radio Button Values
          Markus Schneider

          Not sure, if I got it well...


          The field with the information has to be in the parent table (patients)


          that field gets it's data from a value-list, the items in the value-list are coming from Your 'history-table). So, each patient will have it's own values in that field.


          You'll have already a value-list - but IMHO not an own field in the patient-table

          • 2. Re: Saving Radio Button Values

            Not sure if i can understand your reply.

            • 3. Re: Saving Radio Button Values

              If you have the relationship set (similar to):

              Patient::patientID = History::patientID



              Patient::patientID is the primary key (auto-enter number in that table)

              History::patientID is a number field (not auto-enter) as a "foreign key"

              (by the way, History should have its own primary auto-enter key field, historyID, for example)



              you allow creating related records (in the relationship dialog) IN History



              put these related fields on the Patient layout:


              History::Anticoagulants (formatted as radio with your value list)

              History::Diabetes (formatted as radio with your value list)

              History::Smoking (formatted as radio with your value list)


              I think that the part you may be missing is in the relationship dialog to allow creation. You can click the "=" symbol in the graph to show the dialog. You may need to take a screen shot, so we can verify you have it set up correctly.


              1 of 1 people found this helpful
              • 4. Re: Saving Radio Button Values

                Thank you very much Beverly, much appreciated!!


                I'm attaching the photo just for the information! Values are saved, I CANNOT understand though, why making a relationship just to the ID, and secondly, why my History::patientID should be a non auto-enter serial number. I did put it as a simple non-auto serial number in the end.
                Sorry for the greek language of the script, you'll get the point!






                Screen Shot 2016-05-14 at 22.26.52.png

                • 5. Re: Saving Radio Button Values

                  Relationships have a PRIMARY KEY which should be unique in the 'parent' table. And in the child table the FOREIGN KEY matches the parent.


                  Some relationship are more than one-to-one, such as you have. (Each patients may have many visits, for example.)


                  If you auto-enter into a foreign key, it will probably not match its parent and you've lost the relationship.


                  History can (and should have) its own primary (unique) key field, even if it is never used in any relationships. It is good practice and more or less a pain should you need it after records are already created!


                  Keep on asking (new topics if needed). And welcome to FileMaker!!


                  -- sent from myPhone --

                  Beverly Voth