Re: [GENERAL] archive_command not being executed

2017-11-14 Thread Eric D
Hi Jeremy, Thanks for the info on 9.3 vs 9.5. While searching for Paul's suggestion I'd seen the same thing, but didn't "reply all" so my response didn't make it into the mailing list. Regarding your question, as I understand the process, you need to get the WAL files being shipped over to

Re: [GENERAL] jsonb

2017-11-14 Thread John R Pierce
On 11/14/2017 2:30 PM, hmidi slim wrote: I'm trying to use the function to_jsonb and create the name: to_jsonb ('{"key1":" ' || 'text1' || '","key2":" ' || 'text2' || '"}'); But after that I used Objection.js ORM to get data using the query: Product.query().where('id',1).then(prod => {console.log

Re: [GENERAL] jsonb

2017-11-14 Thread Johannes Graën
On 11/14/2017 11:30 PM, hmidi slim wrote: > I'm trying to use the function to_jsonb and create the name: > to_jsonb ('{"key1":" ' || 'text1' || '","key2":" ' || 'text2' || '"}'); This query converts a string into a JSON object that consist of that string. I guess what you intend to accomplish is r

Re: [GENERAL] jsonb

2017-11-14 Thread Merlin Moncure
On Tue, Nov 14, 2017 at 4:30 PM, hmidi slim wrote: > I'm trying to use the function to_jsonb and create the name: > to_jsonb ('{"key1":" ' || 'text1' || '","key2":" ' || 'text2' || '"}'); > But after that I used Objection.js ORM to get data using the query: > Product.query().where('id',1).then(pro

Re: [GENERAL] PGPool in Master-Master mode, is it possible?

2017-11-14 Thread Tatsuo Ishii
> Hello There, > > I need to setup two PGPool Servers in Master-Master mode, First thing I > want to know, is it possible? > > I know we can setup 2 PGPool servers in master-slave mode using watchdog. > http://www.pgpool.net/pgpool-web/contrib_docs/watchdog_master_slave_3.3/en.html > > Could any

Re: [GENERAL] jsonb

2017-11-14 Thread hmidi slim
I'm trying to use the function to_jsonb and create the name: to_jsonb ('{"key1":" ' || 'text1' || '","key2":" ' || 'text2' || '"}'); But after that I used Objection.js ORM to get data using the query: Product.query().where('id',1).then(prod => {console.log(prod)}) I think that the problem maybe wit

Re: [GENERAL] jsonb

2017-11-14 Thread Merlin Moncure
On Tue, Nov 14, 2017 at 3:32 PM, hmidi slim wrote: > I have a column name of type 'jsonb' on my table named product. The format > of the column: > name: {"key1": "text1", "key2": "text2"} > > When I make a query to fetch data from the table I got this format: > name: '{"key1": "text1", "key2": "te

[GENERAL] jsonb

2017-11-14 Thread hmidi slim
I have a column name of type 'jsonb' on my table named product. The format of the column: name: {"key1": "text1", "key2": "text2"} When I make a query to fetch data from the table I got this format: name: '{"key1": "text1", "key2": "text2"}' Why does postgresql returns the name such as string typ

Re: [GENERAL] missing public on schema public

2017-11-14 Thread Stephen Frost
Tom, all, * Tom Lane (t...@sss.pgh.pa.us) wrote: > =?iso-8859-1?Q?Bo_Thorbj=F8rn_Jensen?= writes: > > I have some additional info and a fix. > > Firstly steps to reproduce: > > Yeah, I can reproduce this. I suspect it got broken by Stephen's hacking > around with default ACLs. A simple example

Re: [GENERAL] pg 10 crashes on int8_avg_combine

2017-11-14 Thread Dingyuan Wang
ok, I just avoided it using sum(cnt::int) since cnt is small. 2017-11-15 00:25, Tom Lane: > Dingyuan Wang writes: >> PostgreSQL 10.0 on x86_64-pc-linux-gnu, compiled by gcc (Debian 7.2.0-8) >> 7.2.0, 64-bit >> >> (gdb) bt >> #0 int8_avg_combine (fcinfo=0x55bdb92472d8) at >> ./build/../src/backen

Re: [GENERAL] pg_basebackup running from a remote machine

2017-11-14 Thread Laurenz Albe
rakeshkumar464 wrote: > If pg_basebackup is run from a remote machine with compress option --gzip , > compress level 9, > will the compression occur prior to the data being sent on the network or > after it has been received > at the remote machine. That only means that the output TAR file will be

Re: [GENERAL] pg 10 crashes on int8_avg_combine

2017-11-14 Thread Tom Lane
Dingyuan Wang writes: > PostgreSQL 10.0 on x86_64-pc-linux-gnu, compiled by gcc (Debian 7.2.0-8) > 7.2.0, 64-bit > > (gdb) bt > #0 int8_avg_combine (fcinfo=0x55bdb92472d8) at > ./build/../src/backend/utils/adt/numeric.c:4285 I think this is the same issue being discussed at https://www.postgres

[GENERAL] PGPool in Master-Master mode, is it possible?

2017-11-14 Thread Vikas Sharma
Hello There, I need to setup two PGPool Servers in Master-Master mode, First thing I want to know, is it possible? I know we can setup 2 PGPool servers in master-slave mode using watchdog. http://www.pgpool.net/pgpool-web/contrib_docs/watchdog_master_slave_3.3/en.html Could anyone please enlight

[GENERAL] pg 10 crashes on int8_avg_combine

2017-11-14 Thread Dingyuan Wang
Hi, PostgreSQL constantly crashes on this query: select dategrid, category, sum(cnt) from v_crime_grid group by dategrid, category; Where v_crime_grid is a materialized view, have columns "dategrid" int4, "category" int4, and "cnt" int8. Version is: PostgreSQL 10.0 on x86_64-pc-linux-gnu, comp

[GENERAL] pg_basebackup running from a remote machine

2017-11-14 Thread rakeshkumar464
If pg_basebackup is run from a remote machine with compress option --gzip , compress level 9, will the compression occur prior to the data being sent on the network or after it has been received at the remote machine. -- Sent from: http://www.postgresql-archive.org/PostgreSQL-general-f1843780.ht

Re: [GENERAL] missing public on schema public

2017-11-14 Thread Tom Lane
=?iso-8859-1?Q?Bo_Thorbj=F8rn_Jensen?= writes: > I have some additional info and a fix. > Firstly steps to reproduce: Yeah, I can reproduce this. I suspect it got broken by Stephen's hacking around with default ACLs. A simple example is $ pg_dump -c -U postgres postgres | grep -i public DROP S

Re: [GENERAL] Retrieve the server's time zone

2017-11-14 Thread Thomas Kellerer
Tom Lane schrieb am 14.11.2017 um 15:36: >> is there any way (short of writing a function in an untrusted PL) >> to determine the actual time zone (or time) of the server OS? > > AFAIK that would only be true if some part of your client stack > is issuing a SET TIMEZONE command. (libpq will do th

Re: [GENERAL] Retrieve the server's time zone

2017-11-14 Thread Tom Lane
Thomas Kellerer writes: > is there any way (short of writing a function in an untrusted PL) to > determine the actual time zone (or time) of the server OS? The default value of the timezone parameter is as close as you'll get in modern versions of PG. > "show timezone" always returns the clien

[GENERAL] Re: PostgreSQL walsender process doesn't exist after "pg_ctl stop -m fast"

2017-11-14 Thread y39chen
Thank you for the explanation. We shall try the latest PostgreSQL 9.6.6 version. -- Sent from: http://www.postgresql-archive.org/PostgreSQL-general-f1843780.html -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.o

Re: [GENERAL] Because PostgreSQL is compiling in old versions of OS?

2017-11-14 Thread Jose Maria Terry Jimenez
El 11/11/17 a las 0:48, DrakoRod escribió: Oh!! Jose Maria TJ wrote You're wrong, that are gcc versions, not OS versions. For example in my CentOS 6 Box cat /etc/redhat-release CentOS release 6.9 (Final) gcc -v [...trimmed...] gcc versión 4.4.7 20120313 (Red Hat 4.4.7-18) (GCC) You're righ

Re: [GENERAL] missing public on schema public

2017-11-14 Thread Bo Thorbjørn Jensen
I have some additional info and a fix. Firstly steps to reproduce: 1. create database: CREATE DATABASE test WITH ENCODING='UTF8' OWNER=postgres CONNECTION LIMIT=-1; -- here public has access to public 2. dump: pg_dump -f testfile.dump -F c -h localhost -U postgres test 3. restore: pg_restore -

[GENERAL] Connection loosing at some places - caused by firewall

2017-11-14 Thread Durumdara
Dear Members! Windows 10, PGSQL 9.4 and 9.6 (Debian with SSL, and Windows without it - it doesn't matter). When I (or my boss) work(s) at home, I got connection lost errors from PGAdmin (3/4) or from other applications too. server closed the connection unexpectedly This probably means the ser

[GENERAL] Retrieve the server's time zone

2017-11-14 Thread Thomas Kellerer
Hello, is there any way (short of writing a function in an untrusted PL) to determine the actual time zone (or time) of the server OS? "show timezone" always returns the client's time zone. localtimestamp also converts the server's time to the client time zone (the one defined by "timezone")