Re: plperl syntax question

2020-03-12 Thread David G. Johnston
On Thursday, March 12, 2020, Rob Sargent wrote: > > The example I saw for qq on the perl site > > print(qq(Welcome to GeeksForGeeks)); > > doesn’t have any quotes in arg to qq > Correct. It also says: qq() operator in Perl can be used in pl

Re: plperl syntax question

2020-03-12 Thread David G. Johnston
On Thursday, March 12, 2020, Rob Sargent wrote: > > > On Mar 12, 2020, at 7:44 PM, stan wrote: > > On Thu, Mar 12, 2020 at 06:37:02PM -0700, David G. Johnston wrote: > > On Thursday, March 12, 2020, stan wrote: > > > my $rv3 = spi_exec_query('$stmt'); > What am I doing wrong here? > > > Putting

Re: plperl syntax question

2020-03-12 Thread Rob Sargent
> On Mar 12, 2020, at 7:44 PM, stan wrote: > > On Thu, Mar 12, 2020 at 06:37:02PM -0700, David G. Johnston wrote: >> On Thursday, March 12, 2020, stan wrote: >>> >>> my $rv3 = spi_exec_query('$stmt'); >>> What am I doing wrong here? >>> >> >> Putting a variable name into a single-quoted str

Re: plperl syntax question

2020-03-12 Thread stan
On Thu, Mar 12, 2020 at 06:37:02PM -0700, David G. Johnston wrote: > On Thursday, March 12, 2020, stan wrote: > > > > my $rv3 = spi_exec_query('$stmt'); > > What am I doing wrong here? > > > > Putting a variable name into a single-quoted string and expecting it to > resolve to the contents of sai

Re: plperl syntax question

2020-03-12 Thread stan
On Thu, Mar 12, 2020 at 06:00:01PM -0600, Rob Sargent wrote: > > > > On Mar 12, 2020, at 5:16 PM, stan wrote: > > > > On Thu, Mar 12, 2020 at 04:58:08PM -0600, Rob Sargent wrote: > >> > >> > >>> On Mar 12, 2020, at 4:49 PM, stan wrote: > >>> > >>> On Thu, Mar 12, 2020 at 04:45:58PM -0600, R

Re: plperl syntax question

2020-03-12 Thread David G. Johnston
On Thursday, March 12, 2020, stan wrote: > > my $rv3 = spi_exec_query('$stmt'); > What am I doing wrong here? > Putting a variable name into a single-quoted string and expecting it to resolve to the contents of said variable instead of being treated as a literal. David J.

Re: polygon && polygon and precision

2020-03-12 Thread Kyotaro Horiguchi
Hello, Patrick. At Thu, 12 Mar 2020 10:16:15 -0700, Patrick Dowler wrote in > I am using polygon datatype with some very small values and discovered that > the overlaps operator appears to break down and give false positives for > values smaller than ~1e-6. I have tested this on 9.5 (.3 and .16

Re: plperl syntax question

2020-03-12 Thread Rob Sargent
> On Mar 12, 2020, at 4:34 PM, stan wrote: > > I am trying to run a query in plperl that uses a Perl variable from the > same function. > > Here is the code snippet: > > my $stmt = qq("SELECT employee_key from employee where id = '$user' ;"); > elog( NOTICE, "stmt = $stmt" ); > my $rv3 = spi

plperl syntax question

2020-03-12 Thread stan
I am trying to run a query in plperl that uses a Perl variable from the same function. Here is the code snippet: my $stmt = qq("SELECT employee_key from employee where id = '$user' ;"); elog( NOTICE, "stmt = $stmt" ); my $rv3 = spi_exec_query('$stmt'); Here is the runtime output: NOTICE: stmt

Re: Migrating from Db2

2020-03-12 Thread Ron
On 3/12/20 3:35 PM, Joe Jess wrote: We are evaluating migrating from Db2. Would appreciate if you can point me to useful resources.  And any guidance on things to what out for. Our set up - About 100+ tables - 300+ user definable functions and tables.  Mainly for analysis and reporting. - S

Migrating from Db2

2020-03-12 Thread Joe Jess
We are evaluating migrating from Db2. Would appreciate if you can point me to useful resources. And any guidance on things to what out for. Our set up - About 100+ tables - 300+ user definable functions and tables. Mainly for analysis and reporting. - Small number of stored procedures called by

Patroni permanent replication slots

2020-03-12 Thread Paul Förster
Hi, I know, this is not 100% a question that belongs here but I hope to get help anyway. I have Patroni 1.6.4 and found in the 1.6.3 the possibility to define permanent replication slots. This seems to work fine in Patroni 1.6.4. But where I would REALLY need it with Patroni 1.3.x and Patroni

polygon && polygon and precision

2020-03-12 Thread Patrick Dowler
I am using polygon datatype with some very small values and discovered that the overlaps operator appears to break down and give false positives for values smaller than ~1e-6. I have tested this on 9.5 (.3 and .16) and 10.10. To reproduce (these examples only differ in the x-axis exponents) and sh

Re: Streaming replication - 11.5

2020-03-12 Thread Nicola Contu
The encryption is at os level. So the drives are encrypted with a password where the db saves data Il gio 12 mar 2020, 15:51 Adrian Klaver ha scritto: > On 3/12/20 4:31 AM, Nicola Contu wrote: > > The replicator is ok and the replicated as well. > > %Cpu(s): 0.2 us, 1.0 sy, 0.0 ni, 94.8 id,

Re: Streaming replication - 11.5

2020-03-12 Thread Adrian Klaver
On 3/12/20 4:31 AM, Nicola Contu wrote: The replicator is ok and the replicated as well. %Cpu(s):  0.2 us,  1.0 sy,  0.0 ni, 94.8 id,  4.0 wa,  0.0 hi,  0.0 si,  0.0 st CPU is really low on both. I am running pg_basebackup again everytime. Any other suggestions? I have to believe their is

RE: pg_restore restores out of order

2020-03-12 Thread Kevin Brannen
>Adrian Klaver wrote: >> Kevin Brannen wrote: >> It goes on to say a trigger is the right way to do this. So yeah, a >> "tightening of the code" seems to be hitting me because of bad code from the >> past. >> >> Problem identified and I'll solve it tomorrow. > >Glad it was solved. > >However, look

Re: Back Port Request for INVALID Startup Packet

2020-03-12 Thread Fabio Ugo Venchiarutti
On 12/03/2020 00:29, Tom Lane wrote: Virendra Kumar writes: Can you please back port patch where if a 0 byte packet sent to PG instance (Health Checks), it starts complaining about invalid startup packet and flood the log which increases log size considerably if the health checks are every 3

Re: Streaming replication - 11.5

2020-03-12 Thread Nicola Contu
The replicator is ok and the replicated as well. %Cpu(s): 0.2 us, 1.0 sy, 0.0 ni, 94.8 id, 4.0 wa, 0.0 hi, 0.0 si, 0.0 st CPU is really low on both. I am running pg_basebackup again everytime. Any other suggestions? Il giorno mer 11 mar 2020 alle ore 23:13 Adrian Klaver < adrian.kla...@