Is there a way to perform simple arithmetic expression in BQL, e.g.,
additions/differences between other columns?
My use case is queries like this one:
3000-01-01 query "investments" "
SELECT account, UNITS(SUM(position)) AS units, COST(SUM(position)) AS cost, VALUE(SUM(position)) AS value
WHERE account ~ '^Assets:.*Investments'
GROUP BY account, currency
ORDER BY account, currency
"
where I'd like to have an extra column showing "value - cost".
TIA,
Cheers
--
Stefano Zacchiroli .
za...@upsilon.cc .
upsilon.cc/zack . . o . . . o . o
Computer Science Professor . CTO Software Heritage . . . . . o . . . o o
Former Debian Project Leader & OSI Board Director . . . o o o . . . o .
« the first rule of tautology club is the first rule of tautology club »