Re: Slow performance with trivial self-joins

2020-02-05 Thread David Rowley
On Thu, 6 Feb 2020 at 11:12, Adam Brusselback wrote: > > > You can create a library of > > reusable views that are small, easy-to-understand and readable. Then > > you build them up into bigger views, and finally query from them. But > > then you end up with lots of (hidden) self-joins. > > I

Re: Slow performance with trivial self-joins

2020-02-05 Thread Adam Brusselback
> You can create a library of > reusable views that are small, easy-to-understand and readable. Then > you build them up into bigger views, and finally query from them. But > then you end up with lots of (hidden) self-joins. I will concur with this use case being pretty common, but also something

Re: Slow performance with trivial self-joins

2020-02-05 Thread Benny Kramek
Thank you for your response. I have tested out the patch in the linked thread and it works very well on a bunch of complex queries that I have tested, improving both the planning time significantly and the execution time drastically. I have also read through the entire linked discussion thread as

Re: Writing 1100 rows per second

2020-02-05 Thread Haroldo Kerry
Arya, We ran into the issue of decreasing insert performance for tables of hundreds of millions of rows and they are indeed due to index updates. We tested TimescaleDB (a pgsql plugin) with success in all use cases that we have. It does a "behind the scenes" single-level partitioning that is

Re: Writing 1100 rows per second

2020-02-05 Thread Arya F
If I run the database on a server that has enough ram to load all the indexes and tables into ram. And then it would update the index on the HDD every x seconds. Would that work to increase performance dramatically? On Wed, Feb 5, 2020, 12:15 PM Justin Pryzby wrote: > On Wed, Feb 05, 2020 at

Re: Writing 1100 rows per second

2020-02-05 Thread Justin Pryzby
On Wed, Feb 05, 2020 at 12:03:52PM -0500, Arya F wrote: > I'm looking to write about 1100 rows per second to tables up to 100 million > rows. I'm trying to come up with a design that I can do all the writes to a > database with no indexes. When having indexes the write performance slows > down

Re: Writing 1100 rows per second

2020-02-05 Thread Laurenz Albe
On Wed, 2020-02-05 at 12:03 -0500, Arya F wrote: > I'm looking to write about 1100 rows per second to tables up to 100 million > rows. I'm trying to > come up with a design that I can do all the writes to a database with no > indexes. When having > indexes the write performance slows down

Writing 1100 rows per second

2020-02-05 Thread Arya F
I'm looking to write about 1100 rows per second to tables up to 100 million rows. I'm trying to come up with a design that I can do all the writes to a database with no indexes. When having indexes the write performance slows down dramatically after the table gets bigger than 30 million rows. I