1 Reply Latest reply on Aug 26, 2009 10:02 AM by philmodjunk

    Using external commands to import a found set of records from one database to another.

    difazioj

      Title

      Using external commands to import a found set of records from one database to another.

      Post

      Hi,

      I have a main database containing student information.  I am creating another database listing equipment ordered for students with special needs. When I am in my equipment database I would like the student name to pop up with the list of students from the main database that have special needs.  I know that I can create a relationship linking the names of the students from the main database to the equipment database, but there are thousands of records in the main database. 

      There are only 350 students from the main database that require equipment.  How can I have just those names pop up in my equipment database.

      Can I create a script to import only those students with special needs? 

      Or is there another way.

       

      Thanks

        • 1. Re: Using external commands to import a found set of records from one database to another.
          philmodjunk
            

          You can use the relationship to filter your value list to show only the related values.

           

          For more on this, look up "Example of a value list that includes only related field values" in the filemaker help file.

           

          One issue to look out for: This approach will restrict your list to just those students who already have a record in the special needs equipment table. That may cause a problem when you add a student's equipment data for the first time.

           

          Another approach:

          If you have a field in the main table that identifies each student with special needs, you can use it in a calculation to restrict your value list.

          Let's say you have a text field that reads "special needs" for each such student.

          Your calculation could read:

          If ( specialFld = "special needs", studentnamefield , "" )

          If you specify this field as your value source in a value list, only those students that have "special needs" in SpecialFld will appear in the value list.

           

          Final design comment: Beware of using name fields to relate tables in a database. You could have two students with the same name and a student's name could change. Either event will cause problems in a database that relates records by name. Use an student ID number instead to avoid this.