Updating a Variable from a Field

I'm creating a calculated field to calculate freight rates based on a fuel surcharge inside a module I call "Freight Rates".  Essentially, I need a place that an employee can enter the price of fuel once and it will automatically calculate all of the rates in the "Freight Rate" module.  Any suggestions on where I can place that field?  The only thing I can think of is placing the field on the record and use a mass update to change them all, but I'm guessing we will end up with 10,000 records that need updated weekly.  Thanks in advance for any suggestions.

Parents
  • Hi Rodney Connor 

    Calculated fields depends on a field, related one or not, so you definitely will need to create another module 'Fuel Prices', which may have a Fuel Type (dropdown maybe) and a Fuel Price (decimal/currency). The module 'Freight Rates' will need a relationship M:1 against 'Fuel Prices' (one 'Fuel Price' has a lots of 'Freight Rates' but a single 'Freight Rates' has one and only one 'Fuel Price').

    This way you can manage thousands of 'Freight Rates' segmented by Fuel Type so by updating the 'Fuel Price' of a specific Fuel Type then all 'Freight Rates' related to that one will be "automagically" updated.

    Remember to make 'Fuel Price' as auditable so you can track Price changes through the time.

    Kind regards

    André Lopes
    Lampada Global
    Skype: andre.lampada
Reply
  • Hi Rodney Connor 

    Calculated fields depends on a field, related one or not, so you definitely will need to create another module 'Fuel Prices', which may have a Fuel Type (dropdown maybe) and a Fuel Price (decimal/currency). The module 'Freight Rates' will need a relationship M:1 against 'Fuel Prices' (one 'Fuel Price' has a lots of 'Freight Rates' but a single 'Freight Rates' has one and only one 'Fuel Price').

    This way you can manage thousands of 'Freight Rates' segmented by Fuel Type so by updating the 'Fuel Price' of a specific Fuel Type then all 'Freight Rates' related to that one will be "automagically" updated.

    Remember to make 'Fuel Price' as auditable so you can track Price changes through the time.

    Kind regards

    André Lopes
    Lampada Global
    Skype: andre.lampada
Children
  • Getting this error now that I've installed the new module when I click on a freight rate.  Ever seen this?

    HTTP: 500 Internal Server Error

    An exception occurred while executing 'SELECT fpc_fuel_price_efc1_est_freight_cost_c.fpc_fuel_price_efc1_est_freight_costfpc_fuel_price_ida id FROM fpc_fuel_price INNER JOIN fpc_fuel_price_efc1_est_freight_cost_c fpc_fuel_price_efc1_est_freight_cost_c ON fpc_fuel_price_efc1_est_freight_cost_c.fpc_fuel_price_efc1_est_freight_costfpc_fuel_price_ida = fpc_fuel_price.id WHERE (fpc_fuel_price_efc1_est_freight_cost_c.fpc_fuel_price_efc1_est_freight_costefc1_est_freight_cost_idb = ?) AND (fpc_fuel_price_efc1_est_freight_cost_c.deleted = ?)' with params ["ff25e106-847a-11e8-8b1b-065d9fb06c5a", 0]: Table 'db_fsgrain.fpc_fuel_price' doesn't exist