Re: [GENERAL] Retrieving comment of rules and triggers

2016-06-09 Thread Michael Paquier
On Fri, Jun 10, 2016 at 6:06 AM, Melvin Davidson wrote: > as the developers have a nasty habit of changing pg_catalog > tables/columns. ... When necessary to improve the quality of the project and the user experience. -- Michael -- Sent via pgsql-general mailing list

Re: [GENERAL] High availability and load balancing ...

2016-06-09 Thread Venkata Balaji N
On Thu, Jun 9, 2016 at 8:01 PM, Sunil N Shinde wrote: > Thanks Venkata. > > > > I am considering latest version now i.e. 9.4 or 9.5 on Linux 6. > > Is there any difference in setup from 9.1 to 9.5? > There is no difference in the setup. Streaming Replication in the

Re: [GENERAL] Retrieving comment of rules and triggers

2016-06-09 Thread Melvin Davidson
On Thu, Jun 9, 2016 at 5:03 PM, Melvin Davidson wrote: > > > On Thu, Jun 9, 2016 at 5:01 PM, David G. Johnston < > david.g.johns...@gmail.com> wrote: > >> On Thu, Jun 9, 2016 at 4:45 PM, Alex Magnum >> wrote: >> >>> Hi, is there a way to retrieve the

Re: [GENERAL] Retrieving comment of rules and triggers

2016-06-09 Thread Adrian Klaver
On 06/09/2016 01:45 PM, Alex Magnum wrote: Hi, is there a way to retrieve the comment of rules and triggers. I worked it out on functions, tables, views but am kind of stuck with rules and triggers. Any help is appreciated. Thanks Alex From psql: \dd some_rule_name \dd some_trigger_name --

Re: [GENERAL] Retrieving comment of rules and triggers

2016-06-09 Thread Melvin Davidson
On Thu, Jun 9, 2016 at 5:01 PM, David G. Johnston < david.g.johns...@gmail.com> wrote: > On Thu, Jun 9, 2016 at 4:45 PM, Alex Magnum wrote: > >> Hi, is there a way to retrieve the comment of rules and triggers. I >> worked it out on functions, tables, views but am kind of

Re: [GENERAL] Retrieving comment of rules and triggers

2016-06-09 Thread David G. Johnston
On Thu, Jun 9, 2016 at 4:45 PM, Alex Magnum wrote: > Hi, is there a way to retrieve the comment of rules and triggers. I worked > it out on functions, tables, views but am kind of stuck with rules and > triggers. > ​

[GENERAL] Retrieving comment of rules and triggers

2016-06-09 Thread Alex Magnum
Hi, is there a way to retrieve the comment of rules and triggers. I worked it out on functions, tables, views but am kind of stuck with rules and triggers. Any help is appreciated. Thanks Alex

Re: [GENERAL] Automate copy - Postgres 9.2

2016-06-09 Thread rob stone
On Wed, 2016-06-08 at 23:50 -0400, David G. Johnston wrote: > > POn Wednesday, June 8, 2016, Patrick B > wrote: > > > ERROR:  syntax error at or near "||" > > > LINE 12:     TO '/var/lib/pgsql/' || crtrow.account_id |... > > > > Which tells me you cannot use an

Re: [GENERAL] Why threads every 30 seconds?

2016-06-09 Thread Bryan Henderson
>>> Looking at audit logs, I see that my Postgresql server generates a new >>> thread >>> precisely every 30 seconds, in two series (so 4 threads every minute). This >>> is an otherwise idle server. > >>> Does anyone know what these threads are for? Just curious. > >Autovacuum, likely. The

Re: [GENERAL] [pg_trgm] Making similarity(?, ?) < ? use an index

2016-06-09 Thread Tom Lane
I wrote: > Greg Navis writes: >> I'm not sure how to make this operator use an index. It seems I need to >> create an operator class but I'm not sure how. > What you'd want to do is add it to the existing operator class and then > teach the class's support functions

Re: [GENERAL] [pg_trgm] Making similarity(?, ?) < ? use an index

2016-06-09 Thread Tom Lane
Greg Navis writes: > I'm not sure how to make this operator use an index. It seems I need to > create an operator class but I'm not sure how. What you'd want to do is add it to the existing operator class and then teach the class's support functions (mostly, the

Re: [GENERAL] connection pooling, many users, many datasources

2016-06-09 Thread Michael McInness
Pgbouncer worked fine for this. Thanks. On Wed, Jun 8, 2016 at 1:12 PM, Sameer Kumar wrote: > > > On Thu, 9 Jun 2016, 12:50 a.m. Michael McInness, > wrote: > >> I am working with a system that uses JDBC and JNDI-based connection >> pooling. There

Re: [GENERAL] High availability and load balancing ...

2016-06-09 Thread Sunil N Shinde
Thanks Venkata. I am considering latest version now i.e. 9.4 or 9.5 on Linux 6. Is there any difference in setup from 9.1 to 9.5? Thanks & Regards, Sunil N Shinde From: Venkata Balaji N [mailto:nag1...@gmail.com] Sent: 08 June 2016 12:46 To: Sunil N Shinde Cc:

Re: [GENERAL] [pg_trgm] Making similarity(?, ?) < ? use an index

2016-06-09 Thread Greg Navis
Artur, no worries, I'm not writing any code ;-) I did the following: CREATE TYPE trgm_match AS (match TEXT, threshold NUMERIC); CREATE OR REPLACE FUNCTION trgm_check_match (string TEXT, match trgm_match) RETURNS bool AS 'SELECT match.match <-> string <= 1 - match.threshold' LANGUAGE SQL;

[GENERAL] Optimise OR condiditions across multiple joins

2016-06-09 Thread Andrew Beverley
Dear all, Is there a way to efficiently perform OR conditions across multiple joins? For example, I have the following statement: SELECT RECORD.id FROM RECORD left join string ON string.record_id = RECORD.id AND string.layout_id = 6 left join DATE