2 Replies Latest reply on Jul 23, 2010 12:18 AM by AnnemarieJansen

    Drop-down list problems



      Drop-down list problems


      Hi all,

      I've been having some problems to set up drop-down lists for some days now and I can't figure it out! I'm a newbie to Filemaker, which is probably part of the problem :).

      I am building a linguistic database. The main table is called 'Sentences', in which the different sentences that are part of my corpus are listed. This table is connected with various other tables, for instance one called 'Sources', in which the different books from which my sentences come are listed. Most of this information I want to take from these tables into 'Sentences' by use of a portal. I want to use drop-down lists, so I can easily pick for each sentence which book it is from.

      These drop-down lists pose problems, as I can't get them to work properly. The most complicated one I want to make is conditional as well. I was hoping I could get some help on this one from somebody here...

      The specific situation is as follows. I want to access the fields in Sentences from a table called 'Verbs' through a portal, in a drop-down list, which is conditional on the language of the sentence.  

      The relationship structure of this part of my database is as follows. Involved are four tables, two of them join tables (which I need for other purposes):

      They connect in the following way:

      _pk_sentence_ID = _fk_sentence_ID = _fk_verb_ID = _pk_verb_ID

      The information on language comes from a table called 'Languages', and is connected with 'Sentences' as follows:


      _pk_language_ID = _fk_language_ID

      I have no trouble getting fields through the portal from Verbs in Sentences, so I think there is nothing wrong with the relationships (but maybe you will disagree).

      Each verb, sentence, and language has it's own record.

      So: what I want is to put the _fk_verb_ID and the verb_root in my portal (this I have done). Then I want a drop-down list which allows me to get both the value of _fk_verb_ID and the value of verb_root. When I click on either I want it to show me the list of ID's (for _fk_verb_ID) or the list of verbs (for verb_root). Then I want to be able to click on value's from either of these list, and it should fill in BOTH fields. (so when I click on 5 in _fk_verb_ID, and this is the ID for 'laufen' ('to walk' in German), I want it to fill in both 5 in _fk_verb_ID and 'laufen' in verb_root).

      Then, if it is possible I also want to be able to create new records through the portal. So I can fill in the verb_root field in the portal in Sentences the verb root 'gehen' (go in German). If this verb root already has it's own record, I want it to give me either an error message or just ignore my request (and fill in the corresponding ID in _fk_verb_ID!). However, if this is not yet the case, I want it to make a new record, which at that moment also gets it's unique ID. (I have no clue whether this is at all possible!?)

      In addition, I want the list to be displayed for the IDs and verbs to be dependent on the language of the sentence. There will be sentences from many different languages in the database, and I won't need the whole list of all verbs from all languages to be displayed, as this will make things needlessly complicated. Each sentence is already said to belong to a specific language, so how can I use this information to 'filter' my drop-down list of verbs?

      The problem with the list that I have made now is that it won't display the list of records. Once I enter an ID in _fk_verb_ID or a verb in verb_root, it just gives me that combination (5 laufen), and not the whole list, which looks like:

      1 gehen
      2 trinken
      3 lernen
      4 sein
      5 laufen
      etc. etc.

      Also, I have no clue to implement the language specifity in the drop-down list. Any help would be greatly appreciated!

        • 1. Re: Drop-down list problems

          A screen shot of Manage | Database | Relationships would help explain your table structure.

          I've having trouble with this line:

          _pk_sentence_ID = _fk_sentence_ID = _fk_verb_ID = _pk_verb_ID

          I doubt that's a correct relationship.

          Normally a join table links two parent tables like this:

          Sentences::_pk_sentence_ID = JoinTable::_fk_sentence_ID

          Verbs::_pk_verb_ID = JoinTable::_fk_verb_ID

          The verb and sentence ID values do not equal each other as they are completely different number series. The Join table bridges the gap by storing both ID values it separate fields so that many sentences can be linked to many verbs.

          Leaving that aside for a moment, do you know how to set up a two column value list? This approach allows you to see both an ID number and a "name" in the same drop down. Then, if you need to see both values after you release the drop down list of pop up menu, you place the field from the related table next to your value list field.

          There's a knowledge base article on conditional value lists you can find (pick knowledge base from the support menu at the top of this screen) that may be helpful if you haven't already read it.

          • 2. Re: Drop-down list problems

            Hi PhilModJunk,

            thanks for your reply! Yes, there is indeed something wrong with that relationship, I'm trying to fix that now... Thanks for your advice on the knowledge base article, I'll give it a go and read that (haven't done so yet). Hopefully, I can post a more specific question if it still doesn't work after I read that :).