Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 4069 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hi

 

I'm trying to solve a problem regarding excluding certain records from showing in a drop down list. I have a list of volunteer drivers that are available for hire and show in a drop down list, however there are times when a particular driver won't be available due to holidays, sickness, etc. What I'm trying to do is display just those drivers that are available in the driver drop down list. 

 

I have a table that contains all the driver details including both the driver name field as the drop down and a field called status which points to a value list containing the list of availabilities.  I have googled this and been on the forums to read up on value lists and discovered something called conditional value lists which I think may work but I can't get any of the examples or tutorials to work on my problem. I have also tried to move the Status field to a new table and setup a relationship but that doesn't work either. 

 

Could someone point me in the right direction or explain how these conditional value lists work in simple terms? I've also included a screen shot to show what the end result should look like.

post-108780-0-66677300-1378673820_thumb.

Posted

In your value list,   maybe   pick from a calc field you have already filtered those unwanteds, like ifempty

Posted

Hi Thanks for the pointer but how and where do I do this?

Posted

Hi

 

I'm trying to solve a problem regarding excluding certain records from showing in a drop down list. I had posted this on the Filemaker 12 forum but I think it should have been posted here in the first place so I apologise if I'm repeating the question.  

 

The drop down list is located on the main layout and points to a list of volunteer drivers that are available for hire which are held in another table containing all the drivers data. This drivers table also contains a field called Status which points to a value list containing the list of availabilities i.e Holiday, Sick, Left etc as there times when a particular driver won't be available. What I'm trying to do is display just those drivers that are available in the driver drop down list and when I mark them as unavailable in the drivers details Layout they do not show. 

 

I have googled this problem and have been on the forums to read up on drop down lists / value lists and discovered something called conditional value lists which I think may work but I can't get any of the examples or tutorials to work with my problem. If someone has done something similar and has a solution I would be extremely grateful as I've been puzzling over this for a couple of days now. Any help would be greatly appreciated. 

Posted

I moved your topic from "FileMaker Pro 12" to "Value Lists".

 

The General Topics for the versions is reserved for questions on the New tools, functions and features of the version when it was released, not for asking How-To questions. 

 

The Forum has many different topics for this, all you need to do is to pick one that represents what your question is concerning.

 

Lee

Posted

Here's another example.

 

Note that this assumes that each status has a non-empty value, i.e. you don't use a null value (an empty field) to indicate e.g. the inactive status. You can enforce this requirement by using auto-enter and validation rules.

 

Since availability is basically "non-availability”, a selection there will set the status to Inactive; deleting the entry will set the status back to Active.

CVL_eos.fmp12.zip

Posted

A conditional value list is made from a relationship.  In your parent table, create a global field g.filter.  In your example, you would populate it with "available" (or whatever status code you use in Drivers to show that a driver is available).

 

Create a relationship between your Main table and a new Table Occurrence of Drivers and name it AvailableDrivers.  The relationship should be Main::g.filter = AvailableDrivers::status .  Now create a value list of AvailableDrivers::Name using only related records from AvailableDrivers.  The values in the value list will be only those drivers whose status is "available".

  • Plus1 1
Posted

Thanks for the help. This sounds quite easy to do so I'll give this a go and let you know if this has worked for me. 

Posted

Thanks EOS. I've just downloaded the zip file and it looks very concise. I'm just going to try and get my head around it and if I have any questions I'll be back to you.

Posted

I have merged your two topics on this subject. Multiple posts are not allowed, so Please do NOT multiple post the same question.

 

If you need additional information on my action, please contact me by Private Message.

 

Lee

  • 4 weeks later...
Posted

My approach at the moment is as follows. A new table with a global field matching the one on the main table via which I will filter the value list. Problem is when I want to filter the same table via another field, I need a new table, and I can't have this in the same global fields folder. 

 

That seems rather cumbersome, what with having multiple tables to filter value lists.

 

I 'd read it being mentioned here that you can do that with Table Occurrences.

 

Is this correct, and is so, how? It should be rather simple which makes me wonder how I am missing it. 

Posted

That seems rather cumbersome, what with having multiple tables to filter value lists.

 

When you define relationships, you use table occurrences (TOs for short), where a TO is a placeholder/alias/stand-in (take your pick) for the actual table. When creating layouts, defining portals, selecting fields etc., you're always dealing with fields via a specific TO, never via the table itself.

 

So to create another relationship from A to B, create a new global in A (or use an existing one), create a new TO for B and connect it to A where (probably) A::global = B::yourData.

 

Is this correct, and is so, how? It should be rather simple which makes me wonder how I am missing it. 

 

Possibly by not reading up on it in the documentation: http://fmhelp.filemaker.com/fmphelp_12/en/html/relational.11.14.html#1028611

 

Note that the official documentation can be misleading in numerous spots where it reads "table"(s), but actually should read "table occurrence"(s).

  • Plus1 1

This topic is 4069 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.