如何在 filemaker pro 15 的下拉列表中进行过滤

How to filter in dropdown lists in filemaker pro 15

我一直在寻找这个。我不想要一个向下钻取过滤器,我从 1 个下拉列表开始,然后根据一个选择在另一个下拉列表中缩小范围。不,我想过滤 1 个特定的数据库字段。

一个例子:

我有 1 table 个公司。在那 table 我有一个 FK 到 CompanyType(例如供应商,客户,...)

在我的发票表格中,我希望有一个来自我的公司 table 的下拉列表,其中只有客户。(例如,下拉列表中的 CustomerTypeID = 1)

在我的费用表中,我希望有一个来自我的公司 table 的下拉列表,其中只有供应商。(例如,CustomerTypeID = 2 的下拉列表)

想法?非常感谢!

In my invoices Form I want to have a dropdown from my Companies table with only the Customers in. (so, for example, dropdown where CustomerTypeID = 1)

  1. 在你的Invoicestable中定义一个未存储的计算字段 cConstant1(结果为数字)并输入:

    1
    

    作为公式。

  2. 定义 Invoices 与新出现的 Companies table(我们将其命名为 Customers)为:

    Invoices::cConstant1 = Customers::CustomerTypeID
    
  3. 定义您的值列表以使用 Customers::CompanyID 中的值,仅包括从 Invoices 开始的相关值。


或者,在公司 table =

中定义一个名为 cCustomerID 的计算字段
If ( CustomerTypeID = 1 ; CompanyID )

并定义您的值列表以使用此字段。