Re: [GENERAL] Ordering of window functions with no order specified?

2017-06-14 Thread Andreas Kretschmer
Am 15.06.2017 um 06:34 schrieb Ken Tanzer: Hi. If you use a window function and don't specify an order, will the rows be processed in the same order as the query results? In this particular case, I'm wondering about row_number(), and whether I explicitly need to repeat the ordering that's

Re: [GENERAL] Ordering of window functions with no order specified?

2017-06-14 Thread David G. Johnston
On Wednesday, June 14, 2017, Ken Tanzer wrote: > > SELECT a,b,c,row_number() > OVER (PARTITION BY a) -- Do I need an ORDER BY c,b here? > Yes. > FROM foo > ORDER BY c,b > Also, I'm interested in both what if any behavior is guaranteed, and what > gets done in practice.

[GENERAL] Ordering of window functions with no order specified?

2017-06-14 Thread Ken Tanzer
Hi. If you use a window function and don't specify an order, will the rows be processed in the same order as the query results? In this particular case, I'm wondering about row_number(), and whether I explicitly need to repeat the ordering that's already specified in the query? SELECT

Re: [GENERAL] Repmgr + pgbouncer - Notification of master promotion to application level ...

2017-06-14 Thread Andreas Kretschmer
Am 15.06.2017 um 01:18 schrieb Martin Goodson: I'm just wondering how people may have implemented this. Do people setup pgbouncer nodes on the database servers themselves, on application servers, in the middle tier between the application and database, and so forth, or some combination of

Re: [GENERAL] Repmgr + pgbouncer - Notification of master promotion to application level ...

2017-06-14 Thread Martin Goodson
On 14/06/2017 19:54, Rory Campbell-Lange wrote: On 14/06/17, Martin Goodson (kaema...@googlemail.com) wrote: The new master's repmgr promote script will execute commands to pause pgbouncer, reconfigure pgbouncer to point to the new database address, and then resume. You could just move the

Re: [GENERAL] Repmgr + pgbouncer - Notification of master promotion to application level ...

2017-06-14 Thread Rory Campbell-Lange
On 14/06/17, Martin Goodson (kaema...@googlemail.com) wrote: > The new master's repmgr promote script will execute commands to pause > pgbouncer, reconfigure pgbouncer to point to the new database address, and > then resume. You could just move the service ip address at the new postgresql master

[GENERAL] Repmgr + pgbouncer - Notification of master promotion to application level ...

2017-06-14 Thread Martin Goodson
Hello. Currently we're running all our PostgreSQL databases on ESX Stretch Clusters, but our company is looking at moving away from those to a private cloud solution. I'm informed that, going forward, new servers provisioned for us to install PostgreSQL databases on will be entirely

Re: [GENERAL] ERROR: type " " does not exist

2017-06-14 Thread Alexander Farber
Good evening everyone, I apologize for the delay in replying and that you had to "reverse engineer" my question. This turned out indeed to be a special char problem. On MBA with macOS Sierra 10.12.5 I am using Postgres 9.5.4.1 of postgresapp.com. At the psql prompt I had copy-pasted: words=>

Re: [GENERAL] pg_upgrade --link on Windows

2017-06-14 Thread Bruce Momjian
On Wed, Jun 14, 2017 at 09:59:04AM +0200, Klaus P. Pieper wrote: > > -Ursprüngliche Nachricht- > > > > I apologize for not being smarter on this thread. When I helped with the > > Windows port, I was told Windows didn't have hard links for use by > tablespace > > directories, so I got it

Re: [GENERAL] pg_catalog tables don't have constraints?

2017-06-14 Thread Neil Anderson
That's a great start, thanks! You should put a pointer to that page in the Pg wiki. I think the 1 thing that would really help it though is to show the actual connection/relations of the columns. For example, a line between pg_index and pg_class is not quite as informative as a line from

Re: [GENERAL] pg_upgrade --link on Windows

2017-06-14 Thread Klaus P. Pieper
> -Ursprüngliche Nachricht- > > I apologize for not being smarter on this thread. When I helped with the > Windows port, I was told Windows didn't have hard links for use by tablespace > directories, so I got it into my head that Windows didn't have hard links. > Therefore, when I was