Total Quanity Calculations

Hi all,
I would like to calculate total number of medicine , already sent to a health worker.

For example:

Day 1, 10 paracetamol packs was sent to the Clinic. Type in quantity 10 packs
On the case
Detail , I want to display Total Quantity = 10 packs

Day 2, 20 paracetamol packs was sent to clinic. type quantity 20.
Total Quantity Display = 30 Packs

Day 3, 5 packs are sent again. type quantity 5. Total Quantity display= 35 packs… etc.

How can I do this using CommCare? I tried with sum function but it's doesn't work.
And also would like to add medicine and reduces medicine from original quantity.

Best Regards

Hi Lin,

CommCare tracks data over time with Cases, have you already configured a type of case which represents the Health worker receiving the medicine?

If your Health Worker is represented by the user of the device, you can store the ongoing quantity on a User Case model, which can streamline the configuration.

Dear Clayton,

Thanks you for comment and answer.
Which type of case represent the health worker receiving the medicine?

Just we use community edition for this project. Not CommCare Tracks.
Can we use hidden calculation for this value? another one question , can we use the case always open?

Because we use this value for next form for add medicine , deuce medicine and total stock.

Best Regards,