Here are some examples showing modifying a journal based on a query: Delete
entry
<https://github.com/jbms/beancount-import/blob/master/beancount_import/delete_transactions.py>
| Rename account
<https://github.com/jbms/beancount-import/blob/master/beancount_import/rename_account.py>
.
It takes a full beancount SQL query and executes it on a journal. You could
use that part and strip out the parts that stage changes to the journal.
You could run the query you've got there and then do some postprocessing to
sum up the accounts accordingly.

On Sat, Jan 16, 2021 at 1:24 PM Aaron Stacy <[email protected]> wrote:

> HI all! I'd like to make a customized income statement where some accounts
> are added together. For example, I'd like to know all income for the past
> month, whether it was Income:Hooli:Salary or Income:Hooli:RSU's. I can get
> pretty close with the query:
>
>     select account, sum(position) from open on 2020-12-01 close on
> 2020-12-31 where account ~ "Income" group by account order by account;
>
> But then I need to go through and sum the specific accounts I happen to
> care about. I'm comfortable importing beancount, using it to parse my
> ledger, and iterating through expenses, but can someone point me to what
> I'd do to get the open on/close on part?
>
> Thanks!
>
> --
> You received this message because you are subscribed to the Google Groups
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/beancount/26067fa0-0a9a-41ec-9b5d-2f62c9714ff0n%40googlegroups.com
> <https://groups.google.com/d/msgid/beancount/26067fa0-0a9a-41ec-9b5d-2f62c9714ff0n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/CACGEkZuyizpMQY8n5BUM6FYiFLskUP5ABoZ1nxSj-sm0kR7LoQ%40mail.gmail.com.

Reply via email to