I have a table called 'tbl_abcd' with columns 'id, user_id', 'carbon_value', 'total_carbon' and 'area'in which id is the primary key.I want to write a trigger function when user update any change in 'carbon_value' column and that trigger will invoke a function that should update 'total_carbon' column value that will be calculated by the formula 'area*carbon_value' for which total_carbon will be changed.
for example carbon_value = 3, area = 5hectare, total_carbon = 3*5 = 15. when carbon value will changed automatically total carbon will be changed.
Any help will be highly appreciated. Rutuparna Panda