Re: [GENERAL] Postgres and timezones

2016-01-21 Thread Steve Rogerson
On 20/01/16 19:19, Vik Fearing wrote: > On 01/20/2016 04:24 PM, Steve Rogerson wrote: >>> Postgres doesn't store original TZ. It does recalculation to local TZ. If >>> you >>> need original TZ, you have to store it separetely. >>> >> >> I know and that's what I'm trying to deal with. Given I know

Re: [GENERAL] adding a bdr node using bcv backup

2016-01-21 Thread (Daniel Stolf)
I'm sorry, I didn't send the correct information about node 2... Here's what I get on all three nodes after I take a snapshot on node 1 and bring it up on node 3... *=== On Node 1: ===* bdrdemo=# select bdr.bdr_get_local_nodeid(); bdr_get_local_nodeid ---

Re: [GENERAL] CoC [Final]

2016-01-21 Thread Geoff Winkless
On 21 January 2016 at 12:36, Chris Travers wrote: > I still side with the Scandinavian approach of passing general laws and > trusting judges to apply them in line with moral rather than purely legal > principles. I believe that it's generally accepted that people will

Re: [GENERAL] CoC [Final]

2016-01-21 Thread Geoff Winkless
On 21 January 2016 at 11:28, Chris Travers wrote: > Resisting the urge to talk about how justice was actually seen in the Dark > Ages Pitchforks. Baying crowds dragging those they consider to be wrongdoers from their beds and tying them to four horses and pulling

Re: [GENERAL] CoC [Final]

2016-01-21 Thread Chris Travers
On Thu, Jan 21, 2016 at 12:39 PM, Geoff Winkless wrote: > On 21 January 2016 at 11:28, Chris Travers > wrote: > > Resisting the urge to talk about how justice was actually seen in the > Dark > > Ages > > Pitchforks. Baying crowds dragging those

Re: [GENERAL] adding a bdr node using bcv backup

2016-01-21 Thread (Daniel Stolf)
Ok, I'm at work now and I have access to my lab... * On Node 1: * bdrdemo=# select bdr.bdr_get_local_nodeid(); bdr_get_local_nodeid --- (6239328434665526195,1,16385) (1 row) bdrdemo=# select bdr.bdr_get_local_node_name(); bdr_get_local_node_name

Re: [GENERAL] CoC [Final]

2016-01-21 Thread Chris Travers
On Thu, Jan 21, 2016 at 11:43 AM, Geoff Winkless wrote: > On 21 January 2016 at 10:37, Chris Travers > wrote: > > At the end of the day this will require human judgment rather than > > formulation. > > Then make it explicit. > > * Disruption of the

Re: [GENERAL] CoC [Final]

2016-01-21 Thread Geoff Winkless
On 20 January 2016 at 20:04, Alvaro Herrera wrote: > "which could be considered" is too open-ended. Since this point is > the one and only that can cause enforcement to occur, it should be more > strict as to what it is that will not be tolerated. I'd propose >

Re: [GENERAL] CoC [Final]

2016-01-21 Thread Chris Travers
On Thu, Jan 21, 2016 at 11:28 AM, Geoff Winkless wrote: > On 20 January 2016 at 20:04, Alvaro Herrera > wrote: > > "which could be considered" is too open-ended. Since this point is > > the one and only that can cause enforcement to occur, it

Re: [GENERAL] CoC [Final]

2016-01-21 Thread Geoff Winkless
On 21 January 2016 at 10:37, Chris Travers wrote: > At the end of the day this will require human judgment rather than > formulation. Then make it explicit. * Disruption of the collaborative space, or patterns of behaviour which the majority of the core team consider to

Re: [GENERAL] Import Schema converting tinyint to Boolean?

2016-01-21 Thread Félix GERZAGUET
On Thu, Jan 21, 2016 at 9:52 AM, Guyren Howe wrote: > I'm converting a MySQL database to a Postgres database by doing a bunch of > CREATE TABLE… AS SELECT * FROM, but the tinyints are coming across as > tinyints. > > Seems like there ought to be an option somewhere to have them

Re: [GENERAL] Recurring bookings

2016-01-21 Thread John R Pierce
On 1/21/2016 2:05 AM, Kevin Waterson wrote: So far this is what I have.. (see below). How can I have recurring bookings for a call? Eg: if the call_frequency is weekly, how can I see a list of dates which this account will be called upon? your call frequency table probably should have a

[GENERAL] Recurring bookings

2016-01-21 Thread Kevin Waterson
So far this is what I have.. (see below). How can I have recurring bookings for a call? Eg: if the call_frequency is weekly, how can I see a list of dates which this account will be called upon? Kind regards Kevin CREATE TABLE call_frequency ( id SERIAL PRIMARY KEY NOT NULL,

[GENERAL] Import Schema converting tinyint to Boolean?

2016-01-21 Thread Guyren Howe
Converting databases is a nightmare. IMPORT SCHEMA almost makes it easy. Almost. I'm converting a MySQL database to a Postgres database by doing a bunch of CREATE TABLE… AS SELECT * FROM, but the tinyints are coming across as tinyints. Seems like there ought to be an option somewhere to have

Re: [GENERAL] adding a bdr node using bcv backup

2016-01-21 Thread (Daniel Stolf)
Hi Craig, how are you? Thanks for your answer. It doesn't seems too complex... Also, it's just a test scenario, I don't intend to use as a production setup or to recommend as such, at least not until I'm 100% sure I got it right... So, assuming I get the snapshot right... The steps would be...

Re: [GENERAL] Variable not found

2016-01-21 Thread Adrian Klaver
On 01/20/2016 07:35 PM, Sachin Srivastava wrote: Dear Folks, I have a question about global variables in Oracle pl/sql package. Where are these variables when package is converted to schema from Oracle to Postgres through Ora2PG Tool? For example, package Best guess it is stored in a table

Re: [GENERAL] Postgres and timezones

2016-01-21 Thread Adrian Klaver
On 01/21/2016 02:58 AM, Steve Rogerson wrote: On 20/01/16 19:19, Vik Fearing wrote: On 01/20/2016 04:24 PM, Steve Rogerson wrote: Postgres doesn't store original TZ. It does recalculation to local TZ. If you need original TZ, you have to store it separetely. I know and that's what I'm

Re: [GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread Adrian Klaver
On 01/21/2016 10:09 AM, John R Pierce wrote: the yum packages for 9.5 apparently changed the path of the socket from /tmp to /var/run/postgresql I have several versions installed on the same dev system running on different ports for 9.1 through 9.4 this was no problem, but since I

Re: [GENERAL] Building PostgreSQL 9.6devel sources with Microsoft Visual C++ 2015?

2016-01-21 Thread Yury Zhuravlev
Tom Lane wrote: Somebody will have to research how one is supposed to get the appropriate locale name now. It's just a bug: https://connect.microsoft.com/VisualStudio/feedback/details/1882835/locale-t-compile-issues-with-vs2015 I spied a solution there and made a patch (in attachment). I came

[GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread John R Pierce
the yum packages for 9.5 apparently changed the path of the socket from /tmp to /var/run/postgresql I have several versions installed on the same dev system running on different ports for 9.1 through 9.4 this was no problem, but since I installed 9.5, I now have to specify -h /tmp -p

Re: [GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread Adrian Klaver
On 01/21/2016 10:09 AM, John R Pierce wrote: the yum packages for 9.5 apparently changed the path of the socket from /tmp to /var/run/postgresql I have several versions installed on the same dev system running on different ports for 9.1 through 9.4 this was no problem, but since I

Re: [GENERAL] Auotmated postgres failover

2016-01-21 Thread John R Pierce
On 1/21/2016 11:07 AM, jwienc...@comcast.net wrote: I'm looking for a tool to automate PostgreSQL cluster management failover in the event the master database were to become unavailable. Currently are manually issuing a "pg_ctl promote" once we become aware that the master database has

Re: [GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread John R Pierce
On 1/21/2016 11:46 AM, Devrim GÜNDÜZ wrote: Hi, On Thu, 2016-01-21 at 10:09 -0800, John R Pierce wrote: >the yum packages for 9.5 apparently changed the path of the socket >from /tmp to /var/run/postgresql I think we use both now. If not, that must be a packaging bug. On my boxes, I can see

Re: [GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread John R Pierce
On 1/21/2016 12:00 PM, John R Pierce wrote: On 1/21/2016 11:46 AM, Devrim GÜNDÜZ wrote: Hi, On Thu, 2016-01-21 at 10:09 -0800, John R Pierce wrote: >the yum packages for 9.5 apparently changed the path of the socket >from /tmp to /var/run/postgresql I think we use both now. If not, that

Re: [GENERAL] Recurring bookings

2016-01-21 Thread cpolish
On 2016-01-21 02:15, John R Pierce wrote: > >How can I have recurring bookings for a call? > >Eg: if the call_frequency is weekly, how can I see a list of dates which > >this account will be called upon? I recommend "Developing time-oriented database applications in SQL", Richard T. Snodgrass,

Re: [GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread Adrian Klaver
On 01/21/2016 12:00 PM, John R Pierce wrote: On 1/21/2016 11:46 AM, Devrim GÜNDÜZ wrote: Hi, On Thu, 2016-01-21 at 10:09 -0800, John R Pierce wrote: >the yum packages for 9.5 apparently changed the path of the socket >from /tmp to /var/run/postgresql I think we use both now. If not, that

Re: [GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread Adrian Klaver
On 01/21/2016 12:00 PM, John R Pierce wrote: On 1/21/2016 11:46 AM, Devrim GÜNDÜZ wrote: Hi, On Thu, 2016-01-21 at 10:09 -0800, John R Pierce wrote: >the yum packages for 9.5 apparently changed the path of the socket >from /tmp to /var/run/postgresql I think we use both now. If not, that

Re: [GENERAL] BDR with postgres 9.5

2016-01-21 Thread Merlin Moncure
On Wed, Jan 20, 2016 at 12:52 PM, Vik Fearing wrote: > On 01/20/2016 11:41 AM, Nikhil wrote: >> Hello All, >> >> >> What is the timeline for BDR with postgres 9.5 released version. > > Currently there are no plans for BDR with 9.5. >

Re: [GENERAL] CoC [Final]

2016-01-21 Thread Steve Litt
On Thu, 21 Jan 2016 10:43:26 + Geoff Winkless wrote: > On 21 January 2016 at 10:37, Chris Travers > wrote: > > At the end of the day this will require human judgment rather than > > formulation. > > Then make it explicit. > > * Disruption of

Re: [GENERAL] Auotmated postgres failover

2016-01-21 Thread Andrew Sullivan
On Thu, Jan 21, 2016 at 11:34:18AM -0800, John R Pierce wrote: > the most difficult part is reliably determining that A) the master has > crashed, and B) fencing the failed old master so it doesn't wake up and > think its still in charge. > And, depending on your workload, C) that you actually

Re: [GENERAL] Building PostgreSQL 9.6devel sources with Microsoft Visual C++ 2015?

2016-01-21 Thread Tom Lane
Yury Zhuravlev writes: > +#if _MSC_VER >= 1800 > + //From VS2012. > + typedef struct localerefcount > + { > + char *locale; > + wchar_t *wlocale; > + ... etc etc ... Ick. Even if that works today, it seems absolutely guaranteed

[GENERAL] HeapTuple to JSON -- composite_to_json()?

2016-01-21 Thread Jason Dusek
Hi All, I am working on a logical decoder and would like to convert a heap tuple to JSON (a HeapTuple obtained from ReorderBufferChange). It is the moral equivalent of tuple_to_stringinfo in test_decode.c: http://doxygen.postgresql.org/test__decoding_8c.html#a3986a57a0308de0150ebd45f7734d464 It

Re: [GENERAL] Building PostgreSQL 9.6devel sources with Microsoft Visual C++ 2015?

2016-01-21 Thread Yury Zhuravlev
Tom Lane wrote: Ick. Even if that works today, it seems absolutely guaranteed to fail in future, as soon as Microsoft either puts back the visible declaration or changes the struct contents. If they've made a conscious decision to not export the struct anymore, it's likely because they intend

Re: [GENERAL] HeapTuple to JSON -- composite_to_json()?

2016-01-21 Thread Jason Dusek
heap_copy_tuple_as_datum looks promising… http://doxygen.postgresql.org/heaptuple_8c.html#abfa9096cd7909cb17a6acfdc7b31b7ad

Re: [GENERAL] long transfer time for binary data

2016-01-21 Thread Johannes
Here are some transferring measurements (from server to client) with the same file. scp +ssl -compression 1.3 sec +ssl +compression 4.6 sec pgadmin select lo_get(12345); -ssl 3.4 sec +ssl +compression 5.5 sec +ssl -compression 4.5 sec psql select lo_get(12345); +ssl -compression

Re: [GENERAL] long transfer time for binary data

2016-01-21 Thread Andy Colson
Am 21.01.2016 um 03:33 schrieb Andy Colson: On 01/20/2016 03:29 PM, Johannes wrote: I noticed transferring a large object or bytea data between client and server takes a long time. For example: An image with a real size of 11 MB could be read on server side (explain analyze) in 81ms. Fine. But

Re: [GENERAL] Building PostgreSQL 9.6devel sources with Microsoft Visual C++ 2015?

2016-01-21 Thread Michael Paquier
On Fri, Jan 22, 2016 at 7:16 AM, Yury Zhuravlev wrote: > Tom Lane wrote: >> Ick. Even if that works today, it seems absolutely guaranteed to fail >> in future, as soon as Microsoft either puts back the visible declaration >> or changes the struct contents. If they've

Re: [GENERAL] How can i add a postgresql connection using inno setup?

2016-01-21 Thread yang
Hi Andreas I installed My project using inno setup program. (Tomcat, PostgreSQL, etc) Oddly, my db was not registered in postgresql. Because the localhost server does not exist on the newly installed postgreSQL. If I add the localhost server and install the project, my db was added to

[GENERAL] Let's Do the CoC Right

2016-01-21 Thread David E. Wheeler
Fellow PostgreSQLers, I can’t help that there are a whole lot of white guys working on this document, with very little feedback from the people who it’s likely to benefit (only exception I spotted in a quick scan was Regina; sorry if I missed you). I suspect that most of you, like me, have

Re: [GENERAL] Variable not found

2016-01-21 Thread Sachin Srivastava
Dear Adrian, So, how the effective way to search this because I have around 1300 tables. Regards, SS On Thu, Jan 21, 2016 at 8:48 PM, Adrian Klaver wrote: > On 01/20/2016 07:35 PM, Sachin Srivastava wrote: > >> Dear Folks, >> >> I have a question about global

Re: [GENERAL] Let's Do the CoC Right

2016-01-21 Thread Rajeev Bhatta
On Friday 22 January 2016 10:55 AM, David E. Wheeler wrote: Fellow PostgreSQLers, I can’t help that there are a whole lot of white guys working on this document, with very little feedback from the people who it’s likely to benefit (only exception I spotted in a quick scan was Regina; sorry if

Re: [GENERAL] Let's Do the CoC Right

2016-01-21 Thread Brar Piening
Am 22.01.2016 um 08:00 schrieb Rajeev Bhatta: I did not read the remainder of the email as classifying someone by anything is inappropriate. Wow! #3 of current CoC "When interpreting the words and actions of others, participants should always assume good intentions." I can see those

Re: [GENERAL] Building PostgreSQL 9.6devel sources with Microsoft Visual C++ 2015?

2016-01-21 Thread Yury Zhuravlev
Michael Paquier wrote: How long do you think it would take for MS 1820 to be fixed and out? Maybe never. I wouldn't personally mind telling to people trying to compile with 1800 that we cannot support it because it is buggy. That's one less wart to have forever in the code. For the user, this

[GENERAL] Let's Do the CoC Right

2016-01-21 Thread David E . Wheeler
Fellow PostgreSQLers, I can’t help that there are a whole lot of white guys working on this document, with very little feedback from the people who it’s likely to benefit (only exception I spotted in a quick scan was Regina; sorry if I missed you). I suspect that most of you, like me, have

Re: [GENERAL] long transfer time for binary data

2016-01-21 Thread Albe Laurenz
Andy Colson wrote: > On 01/21/2016 03:59 PM, Johannes wrote: >> Here are some transferring measurements (from server to client) with the >> same file. >> >> scp >> +ssl -compression 1.3 sec >> +ssl +compression 4.6 sec >> >> pgadmin >> select lo_get(12345); >> -ssl 3.4 sec >> +ssl

[GENERAL] Auotmated postgres failover

2016-01-21 Thread jwiencek3
Hello I'm looking for a tool to automate PostgreSQL cluster management failover in the event the master database were to become unavailable. Currently are manually issuing a "pg_ctl promote" once we become aware that the master database has crashed. Is repmgr a via solution? Please pass

Re: [GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread Devrim GÜNDÜZ
Hi again, On Thu, 2016-01-21 at 21:46 +0200, Devrim GÜNDÜZ wrote: > Sorry about that, but we had to do it. Here is the reason why: https://bugzilla.redhat.com/show_bug.cgi?id=825448 Regards, -- Devrim GÜNDÜZ Principal Systems Engineer @ EnterpriseDB: http://www.enterprisedb.com PostgreSQL

Re: [GENERAL] yum packages for 9.5 vs <=9.4

2016-01-21 Thread Devrim GÜNDÜZ
Hi, On Thu, 2016-01-21 at 10:09 -0800, John R Pierce wrote: > the yum packages for 9.5 apparently changed the path of the socket > from  /tmp to /var/run/postgresql I think we use both now. If not, that must be a packaging bug. On my boxes, I can see that the unix_socket_directory points to