Hacker News new | ask | show | jobs
by beckingz 1096 days ago
Create a view in the database that takes the transactions and returns the data in the format that you want.

It will probably have a bunch of JOIN client.id on transaction.client_id etc etc, but it's the easiest way to get started.

When the view stops running fast enough, switch to a scheduled materialized view.

1 comments

I think I will use this approach

but I think I need to use union to make a single table that is combination of accounting journal tables and view of transaction tables