1 Reply Latest reply on Aug 29, 2011 10:28 AM by philmodjunk

    Conditional Value Lists and Related Fields

    JoelStarkman

      Title

      Conditional Value Lists and Related Fields

      Post

      Hi.

      I'm really struggling with getting my DB to work. I wrote in a while ago and revamped my design based on good advise given to me. I'm still having difficulty to get things working, and have pared down the number of fields I'm trying to reference using value lists.

      Now if have the following: 

      A pop-up value list of SectionNames from my Sections table.

      Based on the value selected there, any DeficiencyType having the same SectionID as the selected SectionName is used to populate the DeficiencyType pop-up value list.

      Once that is selected, I'd like to display it's associated description. The problem I'm having is that the DeficencyTypeID relates to the first matched SectionID, and not to the DeficiencyType I select from the DeficiencyType pop-up. How do I get the correct description to display?

      Thanks from a newbie.

      J

      screen-capture.jpg

        • 1. Re: Conditional Value Lists and Related Fields
          philmodjunk

          First, we'll get your conditional value list working and then I have a comment/question on why you have separate tables for deficiency types and their descriptions...

          You need a different relationship in order for your conditional value list to work.

          Deficiencies::SectionID = DeficiencyTypesBySection::SectionID

          DeficiencyTypesBySection would be a new occurrence of DeficiencyTypes createc by selecting it and then clicking the button with two green plus signs. Deficiencies::SectionID should be formatted with a value list where Sections::SectionID lists values in field 1 and Sections::SectionName lists values in field 2. This way, the user can select a section by name, but the value list enters the ID you need for your value list.

          Now format Deficiencies::DeficiencyTypeID as a value list listing values from DeficiencyTypesBySection::DeficiencyTypeID in field 1 and DeficiencyTypesBySection::Description in Field 2. Select the Include only related values starting from "Deficiencies" option to limit your list to the specified section.

          Now about that Descriptions table: You have set up a relaitonship for many descriptions for one deficiency type yet your example screen shots only allow for the display of a single description. Do you really need this table or will the Description field in t the DeficiencyTypes table suffice? If you need to display multiple descriptions, you'll need a portal for this on your layout.