Re: Can postgresql ignore DST ?

2017-12-14 Thread Laurenz Albe
Venkata B Nagothi wrote: > > > We have Timezone configured to Australia/Sydney, we can change that to 11 > > > and do we need to foresee any issues ? > > > > That configuration parameter defines how the client will format > > timestamps to strings and vice versa. > > > > It should not have any o

Re: Can postgresql ignore DST ?

2017-12-14 Thread John R Pierce
On 12/14/2017 9:17 PM, Venkata B Nagothi wrote: On Fri, Dec 15, 2017 at 3:23 PM, Ben Madin > wrote: I'd be a little worried that if you set timezone = 11 for Australia/Sydney you are embedding the daylight savings value, not the standard time value (UTC+1

Re: Can postgresql ignore DST ?

2017-12-14 Thread Venkata B Nagothi
On Fri, Dec 15, 2017 at 3:23 PM, Ben Madin wrote: > I'd be a little worried that if you set timezone = 11 for Australia/Sydney > you are embedding the daylight savings value, not the standard time value > (UTC+10) > Totally agree. We have a weird situation where-in i had to do this and i would l

Re: Can postgresql ignore DST ?

2017-12-14 Thread Ben Madin
I'd be a little worried that if you set timezone = 11 for Australia/Sydney you are embedding the daylight savings value, not the standard time value (UTC+10) If it helps (it may not) we always set our servers to Australia/Brisbane (UTC+10), as Queensland doesn't have daylight savings, and is fairl

Hot standby failing with PANIC: WAL contains references to invalid pages

2017-12-14 Thread TAKATSUKA Haruka
Hi folks, I got the same failure with the following report on Amazon Linux 2017.09 and postgresql95-9.5.8-1.73.amzn1.x86_64. The WAL's RMGR ID and its type (Heap2/VISIBLE) are also same. The servers had worked for over 2 weeks and the standby crashed. Firstly we suspected something low layer cur

Re: Can postgresql ignore DST ?

2017-12-14 Thread Venkata B Nagothi
On Thu, 14 Dec 2017 at 7:28 pm, Laurenz Albe wrote: > Venkata B Nagothi wrote: > > On Thu, 14 Dec 2017 at 4:04 pm, Tom Lane wrote: > > > Venkata B Nagothi writes: > > > > To rule out any application issues, is it possible to get postgresql > to > > > > ignore DST and render all the timestamps w

Re: Does the delete+insert is fater and less cpu consumer than update?

2017-12-14 Thread legrand legrand
If you use partitioned tables, and just want to reload data from some partitions you can then use the truncate partition syntax or develop a procedure like described here https://www.postgresql.org/message-id/am4pr03mb171327323dcd2069a532756190...@am4pr03mb1713.eurprd03.prod.outlook.com Regards

Re: Does the delete+insert is fater and less cpu consumer than update?

2017-12-14 Thread David G. Johnston
On Thu, Dec 14, 2017 at 3:08 PM, hmidi slim wrote: > I didn't make any test for the performance between them and I want first > of all to know if the update consumes more cpu in case of a large amount of > data and with table with join. > Clearing the entire table, via truncate (not delete), and

Re: Does the delete+insert is fater and less cpu consumer than update?

2017-12-14 Thread Tom Lane
hmidi slim writes: > I used an update query to update the modified rows, however when I search > on the net I found that some people said that update is cpu intensive > consumer and delete+insert is faster. It's possible that there are RDBMSes somewhere for which that is true. But as far as Postg

Does the delete+insert is fater and less cpu consumer than update?

2017-12-14 Thread hmidi slim
Hi, I have a table named 'establishment' which has a join with a table 'category' and a table 'product'. I added indexes to foreign keys to enhance the execution time of the update or delete of data. I have to update the table establishment when I get a new data received from an external api. The a

User-defined print format for extension-defined types in psql output

2017-12-14 Thread Peter Devoy
Hi list To make inspecting PostGIS tables in psql easier I have written a function which outputs PostGIS Geometry objects as a string of ASCII art. Please does anyone know if there is there some way I can have my function called automatically by psql instead of me writing it into the query each t

Re: pgstattuple free_percent to high

2017-12-14 Thread Stephen Frost
Greetings Nicola, * Nicola Contu (nicola.co...@gmail.com) wrote: > I think tuning the autovacuum settings may increase performances and remove > dead_tuples but as far as I know, the autovacuum runs a vacuum analyze. > The vacuum analyze won't touch the free_percent of the table. That's not entir

Re: pgstattuple free_percent to high

2017-12-14 Thread Nicola Contu
Hi Rene, thanks for you reply. I think tuning the autovacuum settings may increase performances and remove dead_tuples but as far as I know, the autovacuum runs a vacuum analyze. The vacuum analyze won't touch the free_percent of the table. So I'm trying to find a way to adjust the free percent f

Re: Size of pg_multixact/members increases 11355

2017-12-14 Thread Alvaro Herrera
Yogesh Sharma wrote: > Dear Thomas , > > Thanks for sharing information. > > Is it possible to remove mentioned folder files in some time intervals by > some DB command? > Currently i can not upgrade to 3.6.20. > So please share if any solution is available. If you do not upgrade, you risk getti

Re: Logical replication blocking alter/drop

2017-12-14 Thread Alvaro Herrera
Mark Fletcher wrote: > Hi All, > > Postgres 9.6.5. We run several logical replication processes off our main > postgres server. What we've noticed is that schema changes seem to block > until we halt the logical replication processes. For example, I just did a > 'DROP INDEX CONCURRENTLY' command,

Re: Can postgresql ignore DST ?

2017-12-14 Thread Laurenz Albe
Venkata B Nagothi wrote: > On Thu, 14 Dec 2017 at 4:04 pm, Tom Lane wrote: > > Venkata B Nagothi writes: > > > To rule out any application issues, is it possible to get postgresql to > > > ignore DST and render all the timestamps with timezone offsets of +11 ? > > > > set timezone = 11 > > We h