6 Replies Latest reply on Mar 4, 2014 11:39 PM by SteveDobney

    Setting Multiple values to one field

    SaterInc

      Title

      Setting Multiple values to one field

      Post

      Good morning all,

           I have another question regarding fields, this time I want to store multiple numbers/values to one field.  In this situation I'm making a table that contains all my outgoing shipments with as little data as possible.  One of the fields is for job numbers attached to the delivery slip.  In most cases a del slip contains more than one job number.  What I need for it to do is allow the user to enter in multiple job numbers to the one field, and for filemaker to be able to retrieve those multiple numbers individually.

        • 1. Re: Setting Multiple values to one field
          casey777
             As long as you are using Filemaker 7 or higher, the multiple job numbers for your delivery slips should come from your related jobs table, not in a single field.
          • 2. Re: Setting Multiple values to one field
            philmodjunk
               I agree with TecMan, but if you insist, there are ways to do this using a variety of text functions. You'd store your values, separating them with carriage returns. It's almost guaranteed that doing so will complicate your solution far more than using a table of related values would.
            • 3. Re: Setting Multiple values to one field
              SaterInc
                

              The job numbers are set up in a seperate table, which holds all my important job info. In the job table it lists the outgoing quanity and related D/S#.  Before a shipment is logged out my code checks to see if their is a matching D/S# in the del slip log.  If their is not then it puts you in the below table and asks you to create one. I know i could make a few fields to hold individual job numbers which would work fine, but I want to try and keep the amount of fields on this table down to a minimum.  Is there any way I can store job numbers in that one field similar to the example below, and still be able to retreive them individually?

                My del slip table looks something like this

               

                Del slip #                  customer                      job #               date shipped

                 1000                   CASE FARGO           57000, 57001, 57002      11/2/09      (GOTO RELATED RECORDS)

                 1001                   CNH                      57003                           11/2/09     (GOTO RELATED RECORDS)

                 1003                   CASE FARGO           57004, 57005                                (GOTO RELATED RECORDS)

               

                For example lets say the goto related is a button, when you click it it first searches for any records in the job log under that customer, then it searches for job numbers. So for D/S 1000 i should see the records for jb 57000, 57001, and 57002.  As I stated above i can do this with multiple fields storing the multiple job numbers, but If i can put them all into one i'd rather do it that way.

              • 4. Re: Setting Multiple values to one field
                philmodjunk
                  

                Yes but there's no need.

                 

                Structure your tables like this:

                 

                Shipments:

                Del slip #                  customer               date shipped

                   1000                   CASE FARGO             11/2/09     

                   1001                   CNH                        11/2/09     

                   1003                   CASE FARGO             11/3/09  

                 

                Job List:

                Job #      Del slip #

                57000       1000

                57001       1000

                57002       1000

                57003       1001

                57004       1003

                57005       1003

                 

                You define a relationship linking the two tables by delivery slip number. (You probably already have a job list table and just need to add the Del slip # field if you don't already have it.)

                 

                You can create a summary report for printing delivery slips based on the Job List table, but including fields from the shipments table in a header or sub-summary part:

                 

                Del slip #1000          customer  CASE FARGO    date shipped 11/2/09

                Job #'s:

                57000       

                57001      

                57002     

                 

                There are also ways to set up the report based on Shipments, that converts the list of Job numbers into the format you describe:

                Substitute (List ( Job List::JobNos ) ; "¶" ; ", " )

                 

                (You'll need to your your table and field names in the above expression) 

                                  

                • 5. Re: Setting Multiple values to one field
                  SaterInc
                     Ok, thanks guys, seems i was just overthinking the problem and could even have the entire shipment log be automatically entered.
                  • 6. Re: Setting Multiple values to one field
                    SteveDobney

                         Hi

                         I have the same question as the original one (I'm also a real newb to FMP and trying to use it in the field with FMGo to record information about trees and diseases affecting them).

                         One of the bits of information I want to collect is the symptoms of the disease. There are 6 possible symptoms and they can occur in any combination. Collecting this data on paper, I simply recorded the relevant letter(s): V, N, Y, B, F, P to represent the 6 possible symptoms, so one tree might have "VYP', another tree "NYF" and so on.

                         Is it possible, and acceptable practice, to include all this info in one field like this? I guess it would always be possible later to search and analyse results based on "includes V" or "doesn't include F", etc.

                         But can I have multiple checklist buttons active on FMGo?

                         Suggestions welcome.

                         Cheers