calculating fields and totals RRS feed

  • Question

  • I work in an insurance office and created a database of our clients.  I created field1 [Coverage] with a Lookup table.  Next I created field2 [Rates] with a series if IIF statements dependent on field1 value selected.  That worked fine however, when I attempt to include the results of field2 [Rates] in field3 [Total Premium] it will not include the calculated field.  What am I doing wrong?  Thank you.

    • Edited by kalg0257 Friday, April 28, 2017 8:36 PM
    Friday, April 28, 2017 8:36 PM

All replies

  • Rather than referencing the second control by name, repeat the expression within the expression which returns the value for the third control.

    However, the fact that you are calling the IIF function in the second control's expression does suggest that data is being hard-coded in the expression.  A fundamental principle of the database relational model is the Information Principle (Codd's Rule #1). This requires that all data be stored as values at column positions in rows in tables, and in no other way.

    The relationships between Coverages, Rates and TotalPremiums should be what they are, relationships between tables, each of which represents one of the three entity types.  It then becomes a simple matter of basing a form on a query which returns the rates and total premiums from the two referenced tables.

    Ken Sheridan, Stafford, England

    Saturday, April 29, 2017 12:18 PM