Re: [GENERAL] Is auto-analyze as thorough as manual analyze?

2017-09-23 Thread Melvin Davidson
On Sat, Sep 23, 2017 at 6:10 PM, Jack Christensen wrote: > Just had an issue where a prepared query would occasionally choose a very > bad plan in production. The same data set in a different environment > consistently would choose the index scan. As would be expected,

[GENERAL] Is auto-analyze as thorough as manual analyze?

2017-09-23 Thread Jack Christensen
Just had an issue where a prepared query would occasionally choose a very bad plan in production. The same data set in a different environment consistently would choose the index scan. As would be expected, running analyze on that table in production resolved the issue. However, before I ran

Re: [GENERAL] Is float8 a reference type?

2017-09-23 Thread Paul A Jungwirth
On Sat, Sep 23, 2017 at 9:40 AM, Tom Lane wrote: > I wonder whether you're using up-to-date Postgres headers (ones > where Float8GetDatum is a static inline function). I'm building against 9.6.3 on both machines. I'm not doing anything special to change the compilation

Re: [GENERAL] Is float8 a reference type?

2017-09-23 Thread Tom Lane
Paul A Jungwirth writes: > Since I'm expecting ~10 million elements per array, it seems like > skipping the conversion will have a real effect. I checked the > assembly and do see a difference (on both Mac+clang and Linux+gcc). I wonder whether you're using

Re: [GENERAL] Adding Cyrillic support

2017-09-23 Thread Tom Lane
John R Pierce writes: > On 9/23/2017 1:44 AM, Job wrote: >> how can i add more character support to PostgreSql 9.6? >> I need to also store some information in Cyrillic, for Russian users. > utf-8 should be able to store just about any character. Or there's about four

Re: [GENERAL] Why can't the database owner create schemas and how can I enable that?

2017-09-23 Thread Tom Lane
John R Pierce writes: > On 9/22/2017 10:29 PM, Tim Uckun wrote: >> The app can now connect to the database but it can't create any >> tables, schemas or anything else unless I give it superuser privileges. > that should have worked just fine. Yeah. Note that creating new

Re: [GENERAL] Is float8 a reference type?

2017-09-23 Thread Paul A Jungwirth
On Fri, Sep 22, 2017 at 8:38 PM, Tom Lane wrote: > "Premature optimization is the root of all evil". Do you have good reason > to think that it's worth your time to write unsafe/unportable code? Do > you know that your compiler doesn't turn Float8GetDatum into a no-op >

Re: [GENERAL] shared_buffers smaller than max_wal_size

2017-09-23 Thread Tomas Vondra
Hi, On 09/23/2017 08:18 AM, Vladimir Mihailenco wrote: > Hi, > > I wonder what is the point of setting max WAL size bigger than shared > buffers, e.g. > > shared_buffers = 512mb > max_wal_size = 2gb > > As I understand a checkpoint happens after 2gb of data were modified > (writter to WAL),

Re: [GENERAL] Why can't the database owner create schemas and how can I enable that?

2017-09-23 Thread Melvin Davidson
On Sat, Sep 23, 2017 at 2:33 AM, John R Pierce wrote: > On 9/22/2017 10:29 PM, Tim Uckun wrote: > >> I am setting up a database for an app. So I create a user without >> superuser but with login priveleges >> >> I then create a database and set it's owner to that user like

Re: [GENERAL] Adding Cyrillic support

2017-09-23 Thread John R Pierce
On 9/23/2017 1:44 AM, Job wrote: how can i add more character support to PostgreSql 9.6? I need to also store some information in Cyrillic, for Russian users. Can more characters coexist in the same database? utf-8 should be able to store just about any character. -- john r pierce,

[GENERAL] Adding Cyrillic support

2017-09-23 Thread Job
Dear guys, how can i add more character support to PostgreSql 9.6? I need to also store some information in Cyrillic, for Russian users. Can more characters coexist in the same database? Thank you! F -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to

Re: [GENERAL] Why can't the database owner create schemas and how can I enable that?

2017-09-23 Thread John R Pierce
On 9/22/2017 10:29 PM, Tim Uckun wrote: I am setting up a database for an app. So I create a user without superuser but with login priveleges I then create a database and set it's owner to that user like this... dropdb --if-exists api_development dropuser --if-exists api_user createuser

[GENERAL] shared_buffers smaller than max_wal_size

2017-09-23 Thread Vladimir Mihailenco
Hi, I wonder what is the point of setting max WAL size bigger than shared buffers, e.g. shared_buffers = 512mb max_wal_size = 2gb As I understand a checkpoint happens after 2gb of data were modified (writter to WAL), but shared buffers can contain at most 512mb of dirty pages to be flushed to