1 Reply Latest reply on Aug 2, 2010 12:26 PM by philmodjunk

    Thought it would be simple - list field data



      Thought it would be simple - list field data


      I just don't seem to have a logical mind anymore. Learning programs used to be much easier! Using FM 9. This is for the index to a book. I have a table with a unique field called "entry #", and several fields that can have the same name in them, "owner last name", "co-owner last name", "third owner", "fourth owner".  All of this is in one table.

      I want to be able to do a find for a name over all 4 fields that have owner names in them, and get all the entry #'s associated with that last name inserted into a field called "owner entries", preferably in numerical order. Any owner could have 1 to 10 entry numbers associated with it. I would have a layout listing that name, with the related entry numbers.

      I thought it would be easy, just use  find and sort and then have a List function for a field, but that didn't work. I've tried about 6 different functions, but all return a list giving each instance of the name, with a different entry #, instead of giving one name with the numbers in a list separated by commas, suitable for an index. I read all the similar sounding topics going back about 3 months, but can't find anything, which makes me think it's a really easy thing to do -for most people. I tried doing a script (complete noob there), but it gave me the name over and over also. This seems like such a simple thing, but I am finding that I don't know enough to see when something is possible - or not. Thanks in advance for any help.

      Is there any resource online that gives many, many examples of calculations and scripts? I don't mind spending the time to read and learn, just need a lot more examples. I don't extrapolate well.

        • 1. Re: Thought it would be simple - list field data

          Sounds like a restructuring of your database would simplify things for you. Instead of placing your names in 4 different fields, you could place them in a set of related recors with one "owner" per record.

          Then the list function may serve to get you the values you need, but in a list separated by returns instead of commas. At this point you one step away from what you need, you just need to put the list function inside a substitute function that replaces the returns with a comma and space to get the list you want.