Re: [GENERAL] 9.6 parameters messing up my 9.2 pg_dump/pg_restore

2017-06-29 Thread David G. Johnston
On Thursday, June 29, 2017, Ken Tanzer wrote: > > I think it's great and impressive that you can install and run two > versions simultaneously, but I have found a couple gotchas in the process. > Maybe those are documented somewhere, but if so I haven't seen it. The >

Re: [GENERAL] 9.6 parameters messing up my 9.2 pg_dump/pg_restore

2017-06-29 Thread Ken Tanzer
On Thu, Jun 29, 2017 at 9:34 AM, Jeff Janes wrote: > >> Well sure, I can see it increases your chances of getting _something_ >> restored. But there's also a lot to be said for ensuring that _all_ your >> data restored, and did so correctly, no? >> > > Record the errors,

Re: [GENERAL] duplicate key value violates unique constraint and duplicated records

2017-06-29 Thread Steven Chang
Interesting!! We also met the same situation on PK running on PPAS 9.0 last night. When surfing Internet, got returned this URL : https://www.postgresql.org/message-id/20140811083748.2536.10437%40wrigleys. postgresql.org

Re: [GENERAL] postgres: dbname dbuser 9.9.9.9[2222] PARSE waiting

2017-06-29 Thread Melvin Davidson
On Thu, Jun 29, 2017 at 7:30 PM, Adrian Klaver wrote: > On 06/29/2017 10:03 AM, DrakoRod wrote: > >> To expand information, the application are written in Grails on wildfly >> with >> pool connections. >> > > Do you control the app? > > The app has a pooling component

Re: [GENERAL] duplicate key value violates unique constraint and duplicated records

2017-06-29 Thread Adrian Klaver
On 06/29/2017 02:28 AM, Timokhin Maxim wrote: Hello. We are in process moving to new db from 9.4.8 -> 9.6.3.1. When we did it our application started to throw exception "duplicate key value violates unique constraint" during doing INSERT: How did move from 9.4.8 --> 9.6.3.1? Also where are

Re: [GENERAL] postgres: dbname dbuser 9.9.9.9[2222] PARSE waiting

2017-06-29 Thread Adrian Klaver
On 06/29/2017 10:03 AM, DrakoRod wrote: To expand information, the application are written in Grails on wildfly with pool connections. Do you control the app? The app has a pooling component and you still are having problems, have you looked at what the pooler is actually doing? I didn't

[GENERAL] duplicate key value violates unique constraint and duplicated records

2017-06-29 Thread Timokhin Maxim
Hello.We are in process moving to new db from 9.4.8 -> 9.6.3.1. When we did it our application started to throw exception "duplicate key value violates unique constraint" during doing INSERT: INSERT INTO items (ctime, mtime, pubdate, url, title, description, body, status, fulltext_status, orig_id,

Re: [GENERAL] duplicate key value violates unique constraint and duplicated records

2017-06-29 Thread Melvin Davidson
On Thu, Jun 29, 2017 at 5:28 AM, Timokhin Maxim wrote: > Hello. > We are in process moving to new db from 9.4.8 -> 9.6.3.1. When we did it > our application started to throw exception "duplicate key value violates > unique constraint" during doing INSERT: > > INSERT INTO items

Re: [GENERAL] INSERT INTO: string with apostrophe

2017-06-29 Thread David G. Johnston
On Thu, Jun 29, 2017 at 1:36 PM, Rich Shepard wrote: > On Thu, 29 Jun 2017, Cachique wrote: > > That is correct. You can double the single quotes. Another way is to use >> the E'...' syntax (i.e., E'O\'Brien'). Or you can use the quote_* >> functions ( >>

Re: [GENERAL] PostGreSQL Timeout, auto shutdown and Pkey errors

2017-06-29 Thread Adrian Klaver
On 06/28/2017 11:32 AM, Niel Smith wrote: Hi, So I have a few problems with my PostGreSQL and was hoping you could help me out. one is I'm getting random timeouts and the errors I'm seeing in the logs are What version of Postgres and where did you get it? OS and version? Which logs? On

Re: [GENERAL] INSERT INTO: string with apostrophe

2017-06-29 Thread Rich Shepard
On Thu, 29 Jun 2017, Cachique wrote: That is correct. You can double the single quotes. Another way is to use the E'...' syntax (i.e., E'O\'Brien'). Or you can use the quote_* functions ( https://www.postgresql.org/docs/current/static/functions-string.html) Walter, Thanks for confirming.

Re: [GENERAL] Download 9.6.3 Binaries

2017-06-29 Thread Thomas Kellerer
Andreas Kretschmer schrieb am 23.06.2017 um 20:58: I expected to find binaries for 9.6.3 at https://www.enterprisedb.com/download-postgresql-binaries but I only see 9.6.2. Am I looking at the wrong place? Yeah, use the community version from postgresql.org ;-) Regards, Andreas There are

Re: [GENERAL] Download 9.6.3 Binaries

2017-06-29 Thread Devrim Gündüz
Hi, On Fri, 2017-06-23 at 11:04 -0700, Igal @ Lucee.org wrote: > I expected to find binaries for 9.6.3 at  > https://www.enterprisedb.com/download-postgresql-binaries but I only see  > 9.6.2. > > Am I looking at the wrong place? Our team at EDB fixed the website, sorry for the inconvenience.

[GENERAL] INSERT INTO: string with apostrophe

2017-06-29 Thread Rich Shepard
The syntax for inserting data into a table uses single quotes to identify strings. When I have a string such as O'Brien do I double the single quotes within the string (i.e., 'O''Brien') or is there another way to include such strings? Rich -- Sent via pgsql-general mailing list

[GENERAL] Connecting matlab with postgresql

2017-06-29 Thread Ilya Roublev
Hi, You could use PgMex (http://pgmex.alliedtesting.com/) - high-performance PostgreSQL client library for Matlab that enables a Matlab-based application to communicate with PostgreSQL database in the Matlab native way by passing data in a form of matrices, multi-dimensional arrays and

Re: [GENERAL] postgres: dbname dbuser 9.9.9.9[2222] PARSE waiting

2017-06-29 Thread David G. Johnston
On Thu, Jun 29, 2017 at 10:03 AM, DrakoRod wrote: > I can't close connections on the application side. How I close connections > on the database side? With pg_terminate_backend, pg_cancel_backend or > exists > other function? I didn't want terminate backends because all

Re: [GENERAL] postgres: dbname dbuser 9.9.9.9[2222] PARSE waiting

2017-06-29 Thread DrakoRod
To expand information, the application are written in Grails on wildfly with pool connections. I didn't have time to check pg_locks with detail, I'll configure the connections logs to monitoring those. I can't close connections on the application side. How I close connections on the database

Re: [GENERAL] 9.6 parameters messing up my 9.2 pg_dump/pg_restore

2017-06-29 Thread Jeff Janes
On Thu, Jun 29, 2017 at 12:05 AM, Ken Tanzer wrote: > Thanks for the responses. For me, using the 9.2 binary was the winner. > Shoulda thought of that! > > On Wed, Jun 28, 2017 at 1:30 PM, Tom Lane wrote: > >> >> Generally speaking, it helps a lot if

[GENERAL] [GENERAL] Significant discrepancy in index cost estimation

2017-06-29 Thread Mikhail
Hi guys, I'm loss. I'm running: =# select version(); version -- PostgreSQL 9.6.2 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.8.5 20150623

Re: [GENERAL] RAM, the more the merrier?

2017-06-29 Thread Joshua D. Drake
On 06/29/2017 07:19 AM, Willy-Bas Loos wrote: Hi, We have a postgresql database that is now 1.4TB in disksize and slowly growing. In the past, we've had (read) performance trouble with this database and the solution was to buy a server that can fit the db into memory. It had 0.5 TB of RAM

Re: [GENERAL] RAM, the more the merrier?

2017-06-29 Thread Andreas Kretschmer
Am 29. Juni 2017 16:19:41 MESZ schrieb Willy-Bas Loos : >Hi, > >We have a postgresql database that is now 1.4TB in disksize and slowly >growing. >In the past, we've had (read) performance trouble with this database >and >the solution was to buy a server that can fit the db into

Re: [GENERAL] RAM, the more the merrier?

2017-06-29 Thread Achilleas Mantzios
On 29/06/2017 17:19, Willy-Bas Loos wrote: Hi, We have a postgresql database that is now 1.4TB in disksize and slowly growing. In the past, we've had (read) performance trouble with this database and the solution was to buy a server that can fit the db into memory. It had 0.5 TB of RAM and at

[GENERAL] RAM, the more the merrier?

2017-06-29 Thread Willy-Bas Loos
Hi, We have a postgresql database that is now 1.4TB in disksize and slowly growing. In the past, we've had (read) performance trouble with this database and the solution was to buy a server that can fit the db into memory. It had 0.5 TB of RAM and at the time it could hold all of the data easily.

Re: [GENERAL] PostGreSQL Timeout, auto shutdown and Pkey errors

2017-06-29 Thread Adrian Klaver
On 06/28/2017 11:32 AM, Niel Smith wrote: Hi, So I have a few problems with my PostGreSQL and was hoping you could help me out. one is I'm getting random timeouts and the errors I'm seeing in the logs are What version of Postgres and where did you get it? OS and version? What is the source

Re: [GENERAL] 9.6 parameters messing up my 9.2 pg_dump/pg_restore

2017-06-29 Thread Adrian Klaver
On 06/29/2017 12:05 AM, Ken Tanzer wrote: Thanks for the responses. For me, using the 9.2 binary was the winner. Shoulda thought of that! On Wed, Jun 28, 2017 at 1:30 PM, Tom Lane > wrote: Generally speaking, it helps a lot if you don't

Re: [GENERAL] Is the row version available in SQL?

2017-06-29 Thread Rob Nikander
> On Jun 28, 2017, at 11:39 AM, Chris Travers wrote: > > For that, you could use xmin. That tracks the transaction where the row > first became visible. > On Jun 28, 2017, at 4:34 PM, Merlin Moncure wrote: > > What you are describing is called

Re: [GENERAL] 9.6 parameters messing up my 9.2 pg_dump/pg_restore

2017-06-29 Thread Ken Tanzer
Thanks for the responses. For me, using the 9.2 binary was the winner. Shoulda thought of that! On Wed, Jun 28, 2017 at 1:30 PM, Tom Lane wrote: > > Generally speaking, it helps a lot if you don't insist on restoring the > output in a single transaction. In this case, that