Re: pg_receivexlog or archive_command

2019-10-01 Thread Stephen Frost
Greetings, * Peter Eisentraut (peter.eisentr...@2ndquadrant.com) wrote: > On 2019-09-23 10:25, Vikas Sharma wrote: > > I am wondering which one is the best way to archive the xlogs for Backup > > and Recovery - pg_receivexlog or archive_command. > > I recommend using pg_receivexlog. It has two i

Re: pg_receivexlog or archive_command

2019-10-01 Thread Stephen Frost
Greetings, * Vikas Sharma (shavi...@gmail.com) wrote: > I am wondering which one is the best way to archive the xlogs for Backup > and Recovery - pg_receivexlog or archive_command. > > pg_receivexlog seems best suited because the copied/archived file is > streamed as it is being written to in xlo

Users, Roles and Connection Pooling

2019-10-01 Thread Matt Andrews
Hey all, Here’s a question I’ve been asking for a while and just can’t find an answer to, so I thought I’d ask it here. The answer could be subjective, but here goes... When a web app connects to Postgres via a connection pooler, what is the best way to manage privileges for the connecting user?

Re: Behaviour adding a column with and without a default (prior to PG11)

2019-10-01 Thread Joe Horsnell
Hi Tom, Just thinking about this further, there are other areas where Postgres (correctly, IMO) deviates from the SQL spec and clarifies that in the docs. For example, https://www.postgresql.org/docs/10/datatype-numeric.html#DATATYPE-NUMERIC-DECIMAL states that for a NUMERIC with no precision

Re: Schema dump/restore not restoring grants on the schema

2019-10-01 Thread Adrian Klaver
On 10/1/19 8:49 AM, Mike Roest wrote: Thanks for the reply Tom,    We're going to look at removing the filtering on the pg_restore which I think should allow us to move forward since we have the pg_dump already filtered. It will. If you want to verify do: pg_restore -f testschema.txt test.b

Re: Schema dump/restore not restoring grants on the schema

2019-10-01 Thread Adrian Klaver
On 10/1/19 7:53 AM, Tom Lane wrote: Mike Roest writes: Just trying to find out if something is intended behaviour. When doing a schema filtered pg_dump the created dump file includes the grants on that specific schema (in our case a grant usage to a unprivleged user) but doing a pg_restore

Support for SLES 15 and PostgreSQL 11.x

2019-10-01 Thread Steve Williams
Currently PostgresSQL 11.x can be installed on openSUSE 15 via the Postgres channel. When will SLES 15 itself will be supported? Thanks Steve

Re: Schema dump/restore not restoring grants on the schema

2019-10-01 Thread Mike Roest
Thanks for the reply Tom, We're going to look at removing the filtering on the pg_restore which I think should allow us to move forward since we have the pg_dump already filtered. --Mike

Re: Schema dump/restore not restoring grants on the schema

2019-10-01 Thread Tom Lane
Mike Roest writes: >Just trying to find out if something is intended behaviour. When doing a > schema filtered pg_dump the created dump file includes the grants on that > specific schema (in our case a grant usage to a unprivleged user) but doing > a pg_restore with a -n does not restore that

Re: "Failed to connect to Postgres database" : No usage specified for certificate (update)

2019-10-01 Thread Adrian Klaver
On 9/30/19 9:21 AM, Marco Ippolito wrote: Hi Adrian, important update. After adding in fabric-ca-server-config.yaml ca:   # Name of this CA   name: fabric_ca   # Key file (is only used to import a private key into BCCSP)   keyfile: /etc/ssl/private/fabric_ca.key   # Certificate file (defau

Schema dump/restore not restoring grants on the schema

2019-10-01 Thread Mike Roest
Hi There, Just trying to find out if something is intended behaviour. When doing a schema filtered pg_dump the created dump file includes the grants on that specific schema (in our case a grant usage to a unprivleged user) but doing a pg_restore with a -n does not restore that grant however ind

fetch time included in pg_stat_statements?

2019-10-01 Thread Ayub M
Does the pg_stat_statements.total_time include the time it takes for all fetches of a cursor query. Or is it only the db time taken to execute the query? -- Regards, Ayub

Re: Query Tuning

2019-10-01 Thread Kyotaro Horiguchi
Hello. At Tue, 1 Oct 2019 12:42:24 +0530, Sonam Sharma wrote in > We have a query which is running slow and it's taking 26secs to complete.. > we have run the analyzer also and it's taking the same time. > > Any tool is there for query optimization or any suggestions. EXPLAIN ANALYZE (not jus

Re: pg12 rc1 on CentOS8 depend python2

2019-10-01 Thread Christoph Berg
Re: Devrim Gündüz 2019-09-30 <21705bb57210f01b559ec2f5de8550df586324e2.ca...@gunduz.org> > I think postgresql-contrib-py3 is really the best idea at this point, > otherwise > I cannot see a clean way to make this without breaking existing installations. Users of these (now contrib) modules need

Query Tuning

2019-10-01 Thread Sonam Sharma
We have a query which is running slow and it's taking 26secs to complete.. we have run the analyzer also and it's taking the same time. Any tool is there for query optimization or any suggestions. My query plan looks like this : CTE Scan on approvalwflscreen (cost=8736.21..8737.25 rows=52 width=