[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 fields

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

2014-05-04 Thread Alban Hertroys
On 04 May 2014, at 10:57, alexandros_e 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. The query > returns

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] Server continuously enters to recovery mode.

2014-05-04 Thread Adrian Klaver
On 05/03/2014 04:29 PM, DrakoRod wrote: Hi everybody! I have a problem (really huge problem), I have one server of production, but yesterday in the night I saw this error: *ERROR: could not access status of transaction 2410303155 DETAIL: Could not open file "pg_clog/08FA": No such fil

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

2014-05-04 Thread Tom Lane
Andres Freund 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 but on a 16Gb wor

[GENERAL] Monitoring Pg servers with Microsoft SCOM

2014-05-04 Thread Glen Eustace
I am in the process of deploying Microsoft System Centre Operations Manager and was hoping that somebody had either developed or knew of where I could get hold of a management pack for PostgreSQL. I am not sure whether there is an instrumentation interface into the DB so haven't yet looked at r

Re: [GENERAL] Monitoring Pg servers with Microsoft SCOM

2014-05-04 Thread John R Pierce
On 5/4/2014 4:17 PM, Glen Eustace wrote: I am in the process of deploying Microsoft System Centre Operations Manager and was hoping that somebody had either developed or knew of where I could get hold of a management pack for PostgreSQL. I am not sure whether there is an instrumentation interf

Re: [GENERAL] Monitoring Pg servers with Microsoft SCOM

2014-05-04 Thread Adrian Klaver
On 05/04/2014 04:17 PM, Glen Eustace wrote: I am in the process of deploying Microsoft System Centre Operations Manager and was hoping that somebody had either developed or knew of where I could get hold of a management pack for PostgreSQL. I am not sure whether there is an instrumentation inter

Re: [GENERAL] Monitoring Pg servers with Microsoft SCOM

2014-05-04 Thread Glen Eustace
On 5/05/2014, at 12:26 pm, Adrian Klaver wrote: > On 05/04/2014 04:17 PM, Glen Eustace wrote: >> I am in the process of deploying Microsoft System Centre Operations >> Manager and was hoping that somebody had either developed or knew of >> where I could get hold of a management pack for PostgreS

[GENERAL] monitoring postgresql with Munin

2014-05-04 Thread John R Pierce
I'm using munin to monitor a postgresql server, using the standard munin postgres methods, it gives me quite a comprehensive set of graphs. but, I can't figure out how to use this to monitor more than one postgres instance on the same server... I have 4 instances (on 4 different ports) on a

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_cursor cursor(W, sql[sqlLoad], "mycursor", false); /* Assume you know total number of records returned */ for (size_t idx

Re: [GENERAL] Monitoring Pg servers with Microsoft SCOM

2014-05-04 Thread Tatsuo Ishii
> I am in the process of deploying Microsoft System Centre Operations Manager > and was hoping that somebody had either developed or knew of where I could > get hold of a management pack for PostgreSQL. > > I am not sure whether there is an instrumentation interface into the DB so > haven't yet

Re: [GENERAL] Monitoring Pg servers with Microsoft SCOM

2014-05-04 Thread Glen Eustace
On 5/05/2014, at 3:18 pm, Tatsuo Ishii wrote: >> I am in the process of deploying Microsoft System Centre Operations Manager >> and was hoping that somebody had either developed or knew of where I could >> get hold of a management pack for PostgreSQL. >> >> I am not sure whether there is an i

[GENERAL] Crosstab function

2014-05-04 Thread Hengky Liwandouw
Hi Friends, Could somebody help me with crosstab function ? I have warehouse table: CREATE TABLE tblwarehouse ( id integer NOT NULL, warehousename character varying(20) ); COPY tblwarehouse (id, warehousename) FROM stdin; 2 OFFICE 3 STORE2 \. And product tabl