Auto subtract inventory



I need to subtract the inventory from my Dec Sales table which consist of Quantity and Type.
How can i do it ? Which formula is suitable for me?
Thank you in advance.



Any expert care to help out ?


Is the column “Done” indicating which items need to be subtracted? If so, I think you will need to use a conditional roll-up. On your Dec Sales table, add a column with the following formula:

IF(Done = 1, Quantity, 0)

The result will be a column with only the quantities that are “Done”/“Out”. Then on your Inventory table you can use a roll-up to sum those quantities and subtract from the total.