How can I write a Postgres (SQL) query for FIFO 'closing stock' inventory valuation? – CentOS
Background I need to implement inventory valuation / costing using the FIFO (first-in, first-out) method. I'm running Postgres 11 running on CentOS 7. I've looked at, and tried, a fair number of hypotheses from SO and the wider internet (as…