Hi Guys this may seam a bit of a strange question but here goes:
This is just a basic example so you can understand what I am trying to achieve.
If I have a mysql database with two tables: "liquid_avaliable" and "liquid_records". liquid avliable would have 3 columns id, name, amount. liquid_records would have id, name, amount_used, liquid_avaliable_id.
Would it be possible to everytime a "liquid record" is added that the amount is subtracted from the avaliable table enrty.
The purpose is so you could just do a quick check on the liquid avaliable table to see how much of each you have left.
If anyone could point me in the right direction it would be much appreciated.
The app I'm working on is built in "cakePHP" and my database system is mysql although Postgre sql is also avliable.
Thanks in advance.