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

[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] Call postgres PL/Python stored function from another PL/Python block.

2016-01-13 Thread lodopidolo
Ok, thank you very much. 2016-01-13 19:04 GMT+01:00 Adrian Klaver : > On 01/13/2016 07:47 AM, lodopidolo wrote: > >> Hello. It is possible to call al PL/Python stored function natively from >> another PL/Python function? >> >> Something like: >> >> |createorreplace

[GENERAL] Call postgres PL/Python stored function from another PL/Python block.

2016-01-13 Thread lodopidolo
Hello. It is possible to call al PL/Python stored function natively from another PL/Python function? Something like: create or replace function f1() returns text as $$ return "hello"$$ language 'plpython3u'; do $$begin ... t = f1() ...end;$$ language 'plpython3u'; Regards.

Re: [GENERAL] Call postgres PL/Python stored function from another PL/Python block.

2016-01-13 Thread Pavel Stehule
Hi 2016-01-13 16:47 GMT+01:00 lodopidolo : > Hello. It is possible to call al PL/Python stored function natively from > another PL/Python function? > The function created by CREATE OR REPLACE FUNCTION statement can be called only via special interface, or via SQL

Re: [GENERAL] Call postgres PL/Python stored function from another PL/Python block.

2016-01-13 Thread Jim Nasby
On 1/13/16 9:47 AM, lodopidolo wrote: Hello. It is possible to call al PL/Python stored function natively from another PL/Python function? Stackoverflow is stupid and won't let me post there, but here's what you want: There is no special capability to call other plpython functions. You

Re: [GENERAL] Call postgres PL/Python stored function from another PL/Python block.

2016-01-13 Thread Adrian Klaver
On 01/13/2016 07:47 AM, lodopidolo wrote: Hello. It is possible to call al PL/Python stored function natively from another PL/Python function? Something like: |createorreplace functionf1()returns text as$$return"hello"$$language 'plpython3u';| |do $$begin...t =f1()...end;$$language

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-16 Thread Melvin Davidson
Another good idea is to do a grep FATAL: your_postgres_log and see if PostgreSQL is complaining about anything relating to table. index or WAL access, otherwise, usually the only "acceptable" FATAL's are related to pg_hba.conf authorization or other connection problems. On Mon, Nov 16, 2015 at

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-16 Thread Albe Laurenz
anj patnaik wrote: > How do you tell if a database is corrupted? Are there specific error > messages/symptoms to look for? That's actually a pretty tough question. The standard test is to run "pg_dumpall", see if it finishes without error and if the dump can be restored without error. That

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-15 Thread anj patnaik
How do you tell if a database is corrupted? Are there specific error messages/symptoms to look for? I have tried running multiple readers/writers, inserted data and verified the byte count from doing fetches. I also ran a reboot and checked that the db came back up after it with data. I still

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-13 Thread Albe Laurenz
John McKown wrote: > All of the above make we curious about using NFS for the data files, but > having the WAL files on a > local, perhaps SSD, device.​ I am not knowledgeable about WAL. Of course, I > don't know why the OP wants > to put the database files on an NFS. If the data file storage

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-12 Thread John McKown
On Thu, Nov 12, 2015 at 12:49 PM, Scott Marlowe wrote: > On Thu, Nov 12, 2015 at 11:19 AM, anj patnaik wrote: > > The Linux VM where postgres is running over NFS is in a different > location > > than where I am. Both the NFS mounted storage and VM are

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-12 Thread John R Pierce
On 11/12/2015 10:19 AM, anj patnaik wrote: The Linux VM where postgres is running over NFS is in a different location than where I am. Both the NFS mounted storage and VM are on the same network connected via 1GB ethernet switch. and earlier... I do need reliability and high speed. you

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-12 Thread anj patnaik
The Linux VM where postgres is running over NFS is in a different location than where I am. Both the NFS mounted storage and VM are on the same network connected via 1GB ethernet switch. The physical server for the Linux VM has UPS. Is there any specific test I can run to do power failure? Can

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-12 Thread Scott Marlowe
On Thu, Nov 12, 2015 at 11:49 AM, Scott Marlowe wrote: > On Thu, Nov 12, 2015 at 11:19 AM, anj patnaik wrote: >> The Linux VM where postgres is running over NFS is in a different location >> than where I am. Both the NFS mounted storage and VM are on

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-12 Thread Scott Marlowe
On Thu, Nov 12, 2015 at 11:19 AM, anj patnaik wrote: > The Linux VM where postgres is running over NFS is in a different location > than where I am. Both the NFS mounted storage and VM are on the same network > connected via 1GB ethernet switch. > > The physical server for the

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-11 Thread John R Pierce
On 11/11/2015 12:37 AM, Albe Laurenz wrote: It would be good to know of other pitfalls; I (and no doubt not only I) keep getting asked why we shouldn't run PostgreSQL on NFS when Oracle has no problem with it (and don't tell me that Oracle does not care about data corruption). Last I looked,

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-11 Thread Albe Laurenz
Scott Mead wrote: > Don't do it. Period. I've used 4 big-vendor appliances with NFS as well as > my own server. With > maybe 3 exceptions, most of the 'total-data-loss' scenarios I've dealt with > regarding transactional > data was due to NFS. Can you share more details? What happened and

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-11 Thread Albe Laurenz
John R Pierce wrote: > On 11/11/2015 12:37 AM, Albe Laurenz wrote: > > It would be good to know of other pitfalls; I (and no doubt not only I) > > keep getting asked why we shouldn't run PostgreSQL on NFS when Oracle > > has no problem with it (and don't tell me that Oracle does not care > > about

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-10 Thread Albe Laurenz
anj patnaik wrote: > Can anyone advise if there are problems running postgres over NFS mounted > partitions? > > I do need reliability and high speed. I have got the advice not to use NFS from a number of people who should know, but there are also knowledgable people who use PostgreSQL with

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-10 Thread anj patnaik
Thanks for the feedback. I have setup a second Linux VM (running RHEL 5.11) and Postgres 9.4. I ran some insertions today from a client running on Windows. The client does a loop of 30 updates. I am seeing about 10-20% increase in latency in the case where DB is on NFS (over TCP) compared to

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-10 Thread Scott Mead
On Tue, Nov 10, 2015 at 6:26 PM, anj patnaik wrote: > Thanks for the feedback. I have setup a second Linux VM (running RHEL > 5.11) and Postgres 9.4. I ran some insertions today from a client running > on Windows. The client does a loop of 30 updates. > > I am seeing about

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-10 Thread Scott Marlowe
On Tue, Nov 10, 2015 at 4:26 PM, anj patnaik wrote: > Thanks for the feedback. I have setup a second Linux VM (running RHEL 5.11) > and Postgres 9.4. I ran some insertions today from a client running on > Windows. The client does a loop of 30 updates. > > I am seeing about

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-09 Thread Patric Bechtel
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi Anj, anj patnaik schrieb am 06.11.2015 um 23:37: > Can anyone advise if there are problems running postgres over NFS mounted > partitions? > > I do need reliability and high speed. then don't do this. Period. Put postgres where your data is.

[GENERAL] can postgres run well on NFS mounted partitions?

2015-11-09 Thread anj patnaik
Can anyone advise if there are problems running postgres over NFS mounted partitions? I do need reliability and high speed. Thank you.

Re: [GENERAL] can postgres run well on NFS mounted partitions?

2015-11-09 Thread John McKown
On Mon, Nov 9, 2015 at 1:09 PM, Patric Bechtel wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Hi Anj, > > anj patnaik schrieb am 06.11.2015 um 23:37: > > Can anyone advise if there are problems running postgres over NFS > mounted partitions? > > > > I do

[GENERAL] ?????? [GENERAL] ??: postgres cpu 100% need help

2015-11-08 Thread ????????????
"Bill Moran"<wmo...@potentialtech.com>; : ""<657985...@qq.com>; "pgsql-general"<pgsql-general@postgresql.org>; : Re: [GENERAL] ??: postgres cpu 100% need help On Tue, Oct 27, 2015 at 12:14 PM, Bill Moran <wmo...@poten

[GENERAL] Retrieve postgres password

2015-09-02 Thread ray madigans.org
I have lost/forgotten the postgres password for my installation so I did the following.I edited pg_hba.conf and added an entry: local all all trustrestarted postgresql. loged in as postgres (psql template1 -U postgres) change the postgres password withALTER ROLE postgres PASSWORD fooI edited

Re: [GENERAL] Retrieve postgres password

2015-09-02 Thread Adrian Klaver
On 09/02/2015 04:43 PM, ray madigans.org wrote: I have lost/forgotten the postgres password for my installation so I did the following. I edited pg_hba.conf and added an entry: local all all trust restarted postgresql. loged in as postgres (psql template1 -U postgres) change the postgres

Re: [GENERAL] multiple postgres processes after establishing tcp connection

2015-08-06 Thread Jim Nasby
On 7/31/15 5:52 AM, Andrey Lizenko wrote: If only simple telnet connection started: [postgres@ubuntu12-vm][20150731 06:30:24]:/db2$ telnet 127.0.0.1 5551 Trying 127.0.0.1... Connected to 127.0.0.1. Escape character is '^]'. new postgres process appeared as a child of the first

Re: [GENERAL] scaling postgres - can child tables be in a different tablespace?

2015-08-04 Thread John R Pierce
On 8/4/2015 6:14 AM, Melvin Davidson wrote: As additional advice, to get the best performance, you will want all your tablespaces to be on separate spindles/disks. EG: disk1/tblspc1 disk2/tblspc2 disk3/tblspc3 ... disk99/tblspc99 actually, I find to get best

Re: [GENERAL] scaling postgres - can child tables be in a different tablespace?

2015-08-04 Thread Chris Withers
On 03/08/2015 08:40, Jony Cohen wrote: Servers now days reach very impressive write speeds and at rather low prices - it's simpler to split the write to 2 tables on different tablespaces/devices than 2 servers. This raises an interesting question: can a child table be in a different tablespace

Re: [GENERAL] scaling postgres

2015-08-04 Thread Seref Arikan
On Tue, Aug 4, 2015 at 9:06 AM, Chris Withers ch...@simplistix.co.uk wrote: On 03/08/2015 08:34, Seref Arikan wrote: At what point does postgres stop scaling? What happens when the computational load no longer fits on one machine? What are the options then? I think it is

Re: [GENERAL] scaling postgres

2015-08-04 Thread Chris Withers
On 04/08/2015 09:11, Seref Arikan wrote: I work in healthcare and patient centric records let me consider multiple servers for lots and lots of patients. The engineering team from instagram has been sharing their experience with postgres, which is

Re: [GENERAL] scaling postgres

2015-08-04 Thread Chris Withers
On 03/08/2015 08:34, Seref Arikan wrote: At what point does postgres stop scaling? What happens when the computational load no longer fits on one machine? What are the options then? I think it is hard to come up with blanket responses to generic questions such as What happens

Re: [GENERAL] scaling postgres - can child tables be in a different tablespace?

2015-08-04 Thread Albe Laurenz
Chris Withers wrote: This raises an interesting question: can a child table be in a different tablespace to its parent and other children of that parent? Yes. Inheritance is a logical concept and is independent of physical placement. Yours, Laurenz Albe -- Sent via pgsql-general mailing

Re: [GENERAL] scaling postgres - can child tables be in a different tablespace?

2015-08-04 Thread Melvin Davidson
As additional advice, to get the best performance, you will want all your tablespaces to be on separate spindles/disks. EG: disk1/tblspc1 disk2/tblspc2 disk3/tblspc3 ... disk99/tblspc99 On Tue, Aug 4, 2015 at 5:31 AM, Albe Laurenz laurenz.a...@wien.gv.at wrote:

Re: [GENERAL] scaling postgres

2015-08-03 Thread Seref Arikan
On Mon, Aug 3, 2015 at 8:22 AM, Chris Withers ch...@simplistix.co.uk wrote: On 03/08/2015 08:15, Jony Cohen wrote: SSD disks are cheep these days but they don't like repeated writes/deletes so it might cause problems down the line (hence my first RAM recommendation) as for keeping the raw

[GENERAL] scaling postgres

2015-08-03 Thread Chris Withers
Hi All, I'm curious if there are recommendations for scaling postgres to what, for me, seems like a lot of data... The app in question currently writes around 1.5 billion rows into a table before rolling them up into tables that have a few million roll up rows each. That 1.5 billion row

Re: [GENERAL] scaling postgres

2015-08-03 Thread Jony Cohen
Hi, I'd recommend looking into 2 solutions here, depending if you want to keep the data or not and how fault tolerant is the app (could you loose data from the last hour?) If you could loose some data and you don't intend keeping the whole data set - I'd look at using RAM as your storage - it's

Re: [GENERAL] scaling postgres

2015-08-03 Thread Chris Withers
On 03/08/2015 08:15, Jony Cohen wrote: SSD disks are cheep these days but they don't like repeated writes/deletes so it might cause problems down the line (hence my first RAM recommendation) as for keeping the raw data - you could easily do it if you use partitions, if you have daily

[GENERAL] multiple postgres processes after establishing tcp connection

2015-07-31 Thread Andrey Lizenko
Hello, PostgreSQL 9.4.4 started in usual way [postgres@ubuntu12-vm][20150731 06:26:06]:/db2/master$ pg_ctl start -D /db2/master/ -l serverlog server starting I can see root process for this then: [postgres@ubuntu12-vm][20150731 06:38:36]:/db2/master$ ps -ef | grep bin/postgres | grep -v

[GENERAL] Upgrade postgres cluster on FreeBSD using pg_upgrade

2015-07-19 Thread Amitabh Kant
Hi I need to upgrade a PG cluster from 9.1 to 9.4 running on dedicated FreeBSD 9.2 server. Earlier I followed the simple pg_dump / pg_restore, but now that the cluster has grown to around 700 GB (1 TB total HD size), I am now inclined towards using pg_upgrade. pg_upgrade requires both binary to

Re: [GENERAL] Upgrade postgres cluster on FreeBSD using pg_upgrade

2015-07-19 Thread Joseph Kregloh
It's actually simpler than you think. Here are the steps that I follow: 1. Install 9.4 in another directory, if you compile it from the ports make suere you add the PREFIX flag. For example: cd /usr/ports/databases/postgresql94-server/ make install clean PREFIX=/opt, this will install 9.4 on the

Re: [GENERAL] Upgrade postgres cluster on FreeBSD using pg_upgrade

2015-07-19 Thread Amitabh Kant
On Mon, Jul 20, 2015 at 1:57 AM, Joseph Kregloh jkreg...@sproutloud.com wrote: It's actually simpler than you think. Here are the steps that I follow: 1. Install 9.4 in another directory, if you compile it from the ports make suere you add the PREFIX flag. For example: cd

[GENERAL] next postgres version on Amazon RDS ?

2015-07-06 Thread Marc Mamin
Hello, has anyone some insight on when we can expect a newest 9.4.x Version on RDS ? Or knows a better forum to ask for this? I should upgrade an application DB currently on 9.3 that might go on RDS but I'm a bit reluctant to go only on 9.4.1 ... regards, Marc Mamin

Re: [GENERAL] My postgres is not logging anymore

2015-06-18 Thread Maila Fatticcioni
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 06/18/2015 11:48 AM, Raymond O'Donnell wrote: On 18/06/2015 10:34, Maila Fatticcioni wrote: Hello. I have a postgres cluster made by two nodes with OS Ubuntu 14.04. About two weeks ago I did a minor update of postgres to the version

Re: [GENERAL] My postgres is not logging anymore

2015-06-18 Thread Raymond O'Donnell
On 18/06/2015 13:13, Maila Fatticcioni wrote: On 06/18/2015 11:48 AM, Raymond O'Donnell wrote: On 18/06/2015 10:34, Maila Fatticcioni wrote: Hello. I have a postgres cluster made by two nodes with OS Ubuntu 14.04. About two weeks ago I did a minor update of postgres to the version

[GENERAL] My postgres is not logging anymore

2015-06-18 Thread Maila Fatticcioni
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello. I have a postgres cluster made by two nodes with OS Ubuntu 14.04. About two weeks ago I did a minor update of postgres to the version 9.4.1-1.pgdg70+1. After I had to shutdown the machines and I could start them just last week. Since then

Re: [GENERAL] My postgres is not logging anymore

2015-06-18 Thread Raymond O'Donnell
On 18/06/2015 10:34, Maila Fatticcioni wrote: Hello. I have a postgres cluster made by two nodes with OS Ubuntu 14.04. About two weeks ago I did a minor update of postgres to the version 9.4.1-1.pgdg70+1. After I had to shutdown the machines and I could start them just last week. Since then

[GENERAL] Installing Postgres manually GCC error and libmpfr.so.4 not found

2015-06-11 Thread asmariyaz23
Hi, Due to a root access permissions I have to resort to manually installing postgres from source code available under the ftp site. When I execute ./configure --prefix=dir/path- my config log shows the following error: gcc version 4.9.0 (GCC) configure:3817: $? = 0 configure:3806: gcc -V 5 gcc:

[GENERAL] dump postgres cluster with different encodings

2015-03-05 Thread basti
Hello I have a postgres cluster with following databases davical| pgadmin | UTF8 | en_US.utf8 | en_US.utf8 | test| test | LATIN9| en_US.iso885915 | en_US.iso885915 | foo| postgres | SQL_ASCII |

Re: [GENERAL] dump postgres cluster with different encodings

2015-03-05 Thread basti
Whithout -E there was the same error. The DB was create with: create database davical WITH ENCODING = 'UTF8' LC_CTYPE='en_US.utf8' LC_COLLATE='en_US.utf8' TEMPLATE template0; I have fix the error with localedef -f UTF-8 -i en_US en_US.UTF-8 After a restart of postgres all is fine. Thanks a

Re: [GENERAL] dump postgres cluster with different encodings

2015-03-05 Thread Adrian Klaver
On 03/05/2015 02:48 AM, basti wrote: Hello I have a postgres cluster with following databases davical| pgadmin | UTF8 | en_US.utf8 | en_US.utf8 | test| test | LATIN9| en_US.iso885915 | en_US.iso885915 | foo

[GENERAL] i386 postgres on i686 debian with multiarch

2014-11-30 Thread Damian Dimmich
Hi, I'm trying to set up a replica for a postgres 9.3 instance running on an older i386 debian install, replicating to a 64 bit install. Having enabled multi-arch** support on the 64 bit debian by running: dpkg --add-architecture i386 and trying to install: apt-get install

Re: [GENERAL] i386 postgres on i686 debian with multiarch

2014-11-30 Thread rob stone
On Sun, 2014-11-30 at 15:17 +0400, Damian Dimmich wrote: Hi, I'm trying to set up a replica for a postgres 9.3 instance running on an older i386 debian install, replicating to a 64 bit install. Having enabled multi-arch** support on the 64 bit debian by running: dpkg

Re: [GENERAL] i386 postgres on i686 debian with multiarch

2014-11-30 Thread Damian Dimmich
Hi Rob, Thank you for your response: cat /var/lib/dpkg/arch gives: amd64 i386 I did update after adding i386- I don't think it would have found postgresql-9.3:i386 otherwise. Further reading indicates that packages can explicitly support multi-arch and permit (some) dependent packages to

Re: [GENERAL] Planet Postgres

2014-10-31 Thread Magnus Hagander
On Thu, Oct 30, 2014 at 8:31 PM, Stephen Frost sfr...@snowman.net wrote: * Adrian Klaver (adrian.kla...@aklaver.com) wrote: On 10/30/2014 12:02 PM, Torsten Förtsch wrote: I don't know if this is the right mailing list for my question but I have already emailed pla...@postgresql.org without any

Re: [GENERAL] Planet Postgres

2014-10-31 Thread Torsten Förtsch
On 31/10/14 09:38, Magnus Hagander wrote: I think in this particular case, much of the blame can be placed on everybody being at pgconf.eu last week, and struggling under backlogs. But as Stephen says, the backlog will eventually get worked through, and the moderation happen. I see. No

Re: [GENERAL] DBlink, postgres to DB2

2014-10-30 Thread Postgres India
Hi , While i try to install psqlDDBC, i get this error , i have SUSE Linux Enterprise Server 11 , trying to find a solution still have no idea. ./configure checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe

Re: [GENERAL] DBlink, postgres to DB2

2014-10-30 Thread Pavel Stehule
2014-10-30 8:47 GMT+01:00 Postgres India pgbugin...@gmail.com: Hi , While i try to install psqlDDBC, i get this error , i have SUSE Linux Enterprise Server 11 , trying to find a solution still have no idea. ./configure checking for a BSD-compatible install... /usr/bin/install -c checking

[GENERAL] Planet Postgres

2014-10-30 Thread Torsten Förtsch
Hi, I don't know if this is the right mailing list for my question but I have already emailed pla...@postgresql.org without any response. What is the correct way to get a blog listed on planet postgres? The documented way does not work. I registered my blog on Monday. It still is in Not

Re: [GENERAL] Planet Postgres

2014-10-30 Thread Adrian Klaver
On 10/30/2014 12:02 PM, Torsten Förtsch wrote: Hi, I don't know if this is the right mailing list for my question but I have already emailed pla...@postgresql.org without any response. What is the correct way to get a blog listed on planet postgres? The documented way does not work. I

Re: [GENERAL] Planet Postgres

2014-10-30 Thread Stephen Frost
* Adrian Klaver (adrian.kla...@aklaver.com) wrote: On 10/30/2014 12:02 PM, Torsten Förtsch wrote: I don't know if this is the right mailing list for my question but I have already emailed pla...@postgresql.org without any response. That's the correct place to ask. -general is not. So, what

Re: [GENERAL] DBlink, postgres to DB2

2014-10-30 Thread Devrim Gündüz
Hi, On Thu, 2014-10-30 at 00:47 -0700, Postgres India wrote: configure: error: odbc_config not found (required for unixODBC build) I think you need to install unixODBC-devel rpm via yast. Regards, -- Devrim GÜNDÜZ Principal Systems Engineer @ EnterpriseDB: http://www.enterprisedb.com

Re: [GENERAL] DBlink, postgres to DB2

2014-10-30 Thread Craig Ringer
On 10/22/2014 06:45 PM, Postgres India wrote: Hi, I am trying to connect DB2 from postgres using dblink, is there any configuration required at DB2 and postgres server. You'll need dbi-link (which uses Perl's DBI drivers) or a foreign data wrapper. dblink is for connections between

[GENERAL] Re[2]: [GENERAL] DBlink, postgres to DB2

2014-10-23 Thread Миша Тюрин
http://multicorn.org/ another cool stuff to generalize interconnections Wed, 22 Oct 2014 22:34:06 -0700 от Postgres India pgbugin...@gmail.com: Thanks a lot Remi, Merlin and Pavel...I will give it a try. On Wed, Oct 22, 2014 at 6:36 AM, Merlin Moncure mmonc...@gmail.com wrote: On

[GENERAL] DBlink, postgres to DB2

2014-10-22 Thread Postgres India
Hi, I am trying to connect DB2 from postgres using dblink, is there any configuration required at DB2 and postgres server. If any command string please provide it. Thanks Manmohan. K

Re: [GENERAL] DBlink, postgres to DB2

2014-10-22 Thread Rémi Cura
Hey http://www.postgresql.org/docs/9.3/static/contrib-dblink-connect.html Seems dblink is for postgres to postgres connections. Cheers, Rémi-C 2014-10-22 12:45 GMT+02:00 Postgres India pgbugin...@gmail.com: Hi, I am trying to connect DB2 from postgres using dblink, is there any configuration

Re: [GENERAL] DBlink, postgres to DB2

2014-10-22 Thread Rémi Cura
You may want to use foreign data wrapper (fdw) https://wiki.postgresql.org/wiki/Foreign_data_wrappers Cheers, Rémi-C 2014-10-22 12:50 GMT+02:00 Rémi Cura remi.c...@gmail.com: Hey http://www.postgresql.org/docs/9.3/static/contrib-dblink-connect.html Seems dblink is for postgres to postgres

Re: [GENERAL] DBlink, postgres to DB2

2014-10-22 Thread Pavel Stehule
Hi try to use a Perl implementation https://github.com/davidfetter/DBI-Link There is a DBD driver for DB2 http://search.cpan.org/dist/DBD-DB2/DB2.pod Or you can use a mentioned fdw wrapper - there is ODBC wrapper https://wiki.postgresql.org/wiki/Foreign_data_wrappers#odbc_fdw and you can access

Re: [GENERAL] DBlink, postgres to DB2

2014-10-22 Thread Merlin Moncure
On Wed, Oct 22, 2014 at 5:56 AM, Pavel Stehule pavel.steh...@gmail.com wrote: Hi try to use a Perl implementation https://github.com/davidfetter/DBI-Link There is a DBD driver for DB2 http://search.cpan.org/dist/DBD-DB2/DB2.pod Or you can use a mentioned fdw wrapper - there is ODBC wrapper

Re: [GENERAL] DBlink, postgres to DB2

2014-10-22 Thread Postgres India
Thanks a lot Remi, Merlin and Pavel...I will give it a try. On Wed, Oct 22, 2014 at 6:36 AM, Merlin Moncure mmonc...@gmail.com wrote: On Wed, Oct 22, 2014 at 5:56 AM, Pavel Stehule pavel.steh...@gmail.com wrote: Hi try to use a Perl implementation

Re: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage

2014-10-16 Thread Roopeshakumar Narayansa Shalgar (rshalgar)
Appreciate any replies on this. /rK -Original Message- From: Roopeshakumar Narayansa Shalgar (rshalgar) Sent: Wednesday, October 15, 2014 10:19 PM To: 'Tom Lane'; pgsql-...@postgresql.org; pgsql-general@postgresql.org Subject: RE: [GENERAL] Any postgres API available to get errorcode

Re: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage

2014-10-16 Thread Adrian Klaver
) Sent: Wednesday, October 15, 2014 10:19 PM To: 'Tom Lane'; pgsql-...@postgresql.org; pgsql-general@postgresql.org Subject: RE: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage Thanks Tom, But that's not what I am looking for. I need the 'integer' errorcode equivalent

[GENERAL] Any postgres API available to get errorcode for PQerrorMessage

2014-10-15 Thread Roopeshakumar Narayansa Shalgar (rshalgar)
HI, PQerrorMessage pirints the error message like (no space available,etc). Does postgres provide any API which gives the error code listed in the below appendix; http://www.postgresql.org/docs/9.1/static/errcodes-appendix.html I need the exact error code so that I can shutdown my

Re: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage

2014-10-15 Thread Tom Lane
Roopeshakumar Narayansa Shalgar (rshalgar) rshal...@cisco.com writes: HI, PQerrorMessage pirints the error message like (no space available,etc). Does postgres provide any API which gives the error code listed in the below appendix;

Re: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage

2014-10-15 Thread Rob Sargent
On 10/15/2014 02:17 AM, Roopeshakumar Narayansa Shalgar (rshalgar) wrote: HI, PQerrorMessage pirints the error message like (no space available,etc). Does postgres provide any API which gives the error code listed in the below appendix;

Re: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage

2014-10-15 Thread Roopeshakumar Narayansa Shalgar (rshalgar)
Shalgar (rshalgar) Cc: pgsql-...@postgresql.org; pgsql-general@postgresql.org Subject: Re: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage Roopeshakumar Narayansa Shalgar (rshalgar) rshal...@cisco.com writes: HI, PQerrorMessage pirints the error message like (no space

Re: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage

2014-10-15 Thread John R Pierce
On 10/15/2014 9:48 AM, Roopeshakumar Narayansa Shalgar (rshalgar) wrote: I need the 'integer' errorcode SQLSTATE Error codes are NOT integers, they are strings. note there's stuff in there like 0100C, 01P01, etc. -- john r pierce 37N 122W somewhere on

Re: [GENERAL] Any postgres API available to get errorcode for PQerrorMessage

2014-10-15 Thread Yogesh. Sharma
by postgresql.spec file? Regards, Yogesh From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Rob Sargent Sent: Wednesday, October 15, 2014 10:08 PM To: pgsql-general@postgresql.org Subject: Re: [GENERAL] Any postgres API available to get errorcode

[GENERAL] Any Postgres experts not afraid of the camera?

2014-09-03 Thread Mike Christensen
http://meta.stackoverflow.com/questions/270574/an-experiment-stack-overflow-tv?cb=1

Re: [GENERAL] BDR Postgres

2014-07-31 Thread Adrian Klaver
On 07/30/2014 10:25 PM, Tonny wrote: Hi everyone I read that 2ndQuadrant released bidirectional replication for postgres, know whether this package will enter apt.postgresql.org or if there will be any repository for Debian GNU / Linux? Information is here:

[GENERAL] BDR Postgres

2014-07-30 Thread Tonny
Hi everyone I read that 2ndQuadrant released bidirectional replication for postgres, know whether this package will enter apt.postgresql.org or if there will be any repository for Debian GNU / Linux? thanks -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make

[GENERAL] eclipse-postgres

2014-06-11 Thread Ravi Kiran
hi, How to compile and run the files the source code of postgres in eclipse, how to compile a c program in the backend directory of postgres?? I followed the steps in https://wiki.postgresql.org/wiki/Working_with_Eclipse , but when I build the program nodeNestloop.c in the backend directory, I

[GENERAL] Building Postgres using mingw

2014-05-07 Thread Michael Paquier
Hi all, Following some instructions on the wiki and the docs, I am trying to compile the code using minwg: https://wiki.postgresql.org/wiki/Building_With_MinGW http://www.postgresql.org/docs/devel/static/installation-platform-notes.html#INSTALLATION-NOTES-MINGW After installing mingw-w64 and

Re: [GENERAL] Building Postgres using mingw

2014-05-07 Thread Adrian Klaver
On 05/07/2014 08:27 AM, Michael Paquier wrote: Hi all, Following some instructions on the wiki and the docs, I am trying to compile the code using minwg: https://wiki.postgresql.org/wiki/Building_With_MinGW

Re: [GENERAL] Building Postgres using mingw

2014-05-07 Thread Jeff Janes
On Wed, May 7, 2014 at 8:27 AM, Michael Paquier michael.paqu...@gmail.comwrote: Hi all, Following some instructions on the wiki and the docs, I am trying to compile the code using minwg: https://wiki.postgresql.org/wiki/Building_With_MinGW

Re: [GENERAL] Building Postgres using mingw

2014-05-07 Thread Michael Paquier
On Wed, May 7, 2014 at 10:26 AM, Jeff Janes jeff.ja...@gmail.com wrote: On Wed, May 7, 2014 at 8:27 AM, Michael Paquier michael.paqu...@gmail.com wrote: Hi all, Following some instructions on the wiki and the docs, I am trying to compile the code using minwg:

Re: [GENERAL] C++, Postgres , libpqxx huge query

2014-05-05 Thread Alexandros Efentakis
Thanks John for your answer. The problem is how do I declare the cursor and fetch through C++ and libpq++? And if I fetch 1000 rows at a time, then how do I handle that when I reach the end and there are less than 1000 rows available? Or I need to fetch one row at a time like this

Re: [GENERAL] C++, Postgres , libpqxx huge query

2014-05-05 Thread Alexandros Efentakis
To answer my own question, I adapted http://stackoverflow.com/questions/16128142/how-to-use-pqxxstateless-cursor-class-from-libpqxx try { work W(*Conn); pqxx::stateless_cursorpqxx::cursor_base::read_only, pqxx::cursor_base::owned cursor(W,

[GENERAL] C++, Postgres , libpqxx huge query

2014-05-04 Thread alexandros_e
Hello experts. I have posted this question on stack overflow, but I did not get any detailed answer, so I thought I should cross post here. My apologies. I have to execute an SQL query to Postgres by the following code. The query returns a huge number of rows (40M or more) and has 4 integer

Re: [GENERAL] C++, Postgres , libpqxx huge query

2014-05-04 Thread Alban Hertroys
On 04 May 2014, at 10:57, alexandros_e alexandros...@gmail.com wrote: Hello experts. I have posted this question on stack overflow, but I did not get any detailed answer, so I thought I should cross post here. My apologies. I have to execute an SQL query to Postgres by the following code.

Re: [GENERAL] C++, Postgres , libpqxx huge query

2014-05-04 Thread Andres Freund
Hi, On 2014-05-04 01:57:43 -0700, alexandros_e wrote: I have to execute an SQL query to Postgres by the following code. The query returns a huge number of rows (40M or more) and has 4 integer fields: When I use a workstation with 32Gb everything works but on a 16Gb workstation the query is

Re: [GENERAL] C++, Postgres , libpqxx huge query

2014-05-04 Thread Tom Lane
Andres Freund and...@2ndquadrant.com writes: On 2014-05-04 01:57:43 -0700, alexandros_e wrote: I have to execute an SQL query to Postgres by the following code. The query returns a huge number of rows (40M or more) and has 4 integer fields: When I use a workstation with 32Gb everything works

Re: [GENERAL] C++, Postgres , libpqxx huge query

2014-05-04 Thread alexandros_e
To answer my own question, I adapted How to use pqxx::stateless_cursor class from libpqxx? try { work W(*Conn); pqxx::stateless_cursorpqxx::cursor_base::read_only, pqxx::cursor_base::owned cursor(W, sql[sqlLoad], mycursor, false); /* Assume you know total

[GENERAL] Refresh Postgres SSL certs?

2014-04-09 Thread Paul Jungwirth
Hello, In light of the Heartbleed OpenSSL bug[0,1], I'm wondering if I need to regenerate the SSL certs on my postgres installations[2] (at least the ones listening on more than localhost)? On Ubuntu it looks like there are symlinks at /var/lib/postgresql/9.1/main/server.{crt,key} pointing to

Re: [GENERAL] Refresh Postgres SSL certs?

2014-04-09 Thread Martijn van Oosterhout
On Wed, Apr 09, 2014 at 12:28:14PM -0700, Paul Jungwirth wrote: Hello, In light of the Heartbleed OpenSSL bug[0,1], I'm wondering if I need to regenerate the SSL certs on my postgres installations[2] (at least the ones listening on more than localhost)? On Ubuntu it looks like there are

Re: [GENERAL] Refresh Postgres SSL certs?

2014-04-09 Thread Paul Jungwirth
Have you read the Debian README? /usr/share/doc/postgresql-*/README.Debian.gz Thank you for pointing me to that file. From /etc/share/doc/ssl-cert/README it sounds like the old snakeoil cert is already self-signed, so that's promising. So I take it that psql and the postgres client library

Re: [GENERAL] Refresh Postgres SSL certs?

2014-04-09 Thread Martijn van Oosterhout
On Wed, Apr 09, 2014 at 12:59:53PM -0700, Paul Jungwirth wrote: Have you read the Debian README? /usr/share/doc/postgresql-*/README.Debian.gz Thank you for pointing me to that file. From /etc/share/doc/ssl-cert/README it sounds like the old snakeoil cert is already self-signed, so that's

<    1   2   3   4   5   6   7   8   9   10   >