Re: [GENERAL] [ADMIN] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread Craig Ringer
On 9/08/2011 10:54 PM, c k wrote: Normal python functions returning text etc. are working but when conatining import sys from uuid import getnode as get_mac mac = get_mac() return mac fails. What will be the reason? You still haven't supplied the error message you get when you run this. In

[GENERAL] canceling autovacuum task error

2011-08-10 Thread tamanna madaan
Hi All I am using a cluster setup having postgres-8.4.0 and slon 2.0.4 is being used for replication . It happened that the autovacuum was not running successfully on one of the nodes in cluster and was giving error : 2011-05-13 23:07:42 CDTERROR: canceling autovacuum task 2011-05-13 23:07:42

Re: [GENERAL] Postgres on SSD

2011-08-10 Thread Tomas Vondra
On 10 Srpen 2011, 1:17, Ondrej Ivanič wrote: - What needs to be changed at Postgres/Operating system level? The obvious one is to change random_page_cost (now: 2) and seq_page_cost (now: 4). What else should I look at? Are you sure about this? I'm not quite sure setting seq_page_cost=4 and

Re: [GENERAL] [ADMIN] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread c k
I didn't get any error message. When calling the function from PGAdmin I get error**. When I try to re-execute it, it says 'no connection to the server'. When checked the logs I found 2011-08-09 19:46:00 IST LOG: database system was interrupted; last known up at 2011-08-09

Re: [GENERAL] canceling autovacuum task error

2011-08-10 Thread Scott Marlowe
On Tue, Aug 9, 2011 at 11:07 PM, tamanna madaan tamanna.mad...@globallogic.com wrote: Hi All I am using a cluster setup having postgres-8.4.0 and slon 2.0.4 is being There are known data eating bugs in that version of postgresql, and I personally had issues with earlier 2.0.x releases. There

Re: [GENERAL] [ADMIN] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread Scott Marlowe
On Wed, Aug 10, 2011 at 1:23 AM, c k shreeseva.learn...@gmail.com wrote: When I try to re-execute it, it says 'no connection to the server'. When checked the logs I found 2011-08-09 19:46:00 IST LOG:  database system was interrupted; last known up at 2011-08-09 19:45:17 IST 2011-08-09

Re: [GENERAL] Problem with planner

2011-08-10 Thread hubert depesz lubaczewski
On Tue, Aug 09, 2011 at 05:18:38PM -0400, Tom Lane wrote: hubert depesz lubaczewski dep...@depesz.com writes: I solved the problem by adding enable_bitmapscan = false (and keeping the query in original format, with subselect) which caused the plan to be ok. I doubt that solution is any

Re: [GENERAL] Pgadmin goes missing in Ubuntu

2011-08-10 Thread Chetan Suttraway
On Tue, Aug 9, 2011 at 7:10 PM, Adrian Klaver adrian.kla...@gmail.comwrote: On Tuesday, August 09, 2011 2:18:47 am Adarsh Sharma wrote: Dear all, I installed postgresql from a postgresplus-8.4.1-2-linux-x64 binary and it is working properly in the system.Yesterday i do some work in it.

[GENERAL] PLPGSQL Generic query in trigger doubt

2011-08-10 Thread Mauro
Hi, good morning list I'm writing a generic trigger in plpgsql to provide a system log to my system, but I'm stopped with the folow problem: Example: TABLE STRUCT: table1    fldA    VARCHAR    fldB    VARCHAR    fldC    VARCHAR FUNCTION: DECLARE    myrecord RECORD; -- record that will be

Re: [GENERAL] PLPGSQL Generic query in trigger doubt

2011-08-10 Thread Merlin Moncure
On Wed, Aug 10, 2011 at 8:38 AM, Mauro mauro...@yahoo.com.br wrote: Hi, good morning list I'm writing a generic trigger in plpgsql to provide a system log to my system, but I'm stopped with the folow problem: Example: TABLE STRUCT: table1    fldA    VARCHAR    fldB    VARCHAR    fldC   

[GENERAL] Need to purge applied log from arch_replicate directory

2011-08-10 Thread Alex Lai
Dear all, I am test postgres streaming replication under 9.0.4. The master and slave have been replicated smoothly. In master, I have a directory /path/to/arch_replicate/ to used by slave to access and apply the logs. The arch_replicate directory has been growing without purging any

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread Adrian Klaver
On Tuesday, August 09, 2011 10:13:17 pm c k wrote: Here is the actual function. create or replace function software.python_test() returns text as $body$ import sys from uuid import getnode as get_mac mac = get_mac() return mac $body$ language plpythonu volatile security definer; When

Re: [GENERAL] PLPGSQL Generic query in trigger doubt

2011-08-10 Thread Ioana Danes
Hi Mauro, If you try to determine what fields were changed you can check this post: http://jaime2ndquadrant.blogspot.com/ It might work for you. Ioana --- On Wed, 8/10/11, Mauro mauro...@yahoo.com.br wrote: Hi, good morning list I'm writing a generic trigger in plpgsql to provide a system log

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread c k
I have renamed uuid-ossp.dll to 0uuid-ossp.dll in postgresql's lib directory. But it is also found that postgresql's bin directory is not included in the path. Then started the postgresql again, called the same plpython function again and again server crashed without any details in the log. Also

[GENERAL] Is max connections in a table somewhere?

2011-08-10 Thread Geoffrey Myers
Is max connections in any table in the database I can access? -- Until later, Geoffrey I predict future happiness for America if they can prevent the government from wasting the labors of the people under the pretense of taking care of them. - Thomas Jefferson -- Sent via pgsql-general mailing

Re: [GENERAL] Is max connections in a table somewhere?

2011-08-10 Thread Andy Colson
On 8/10/2011 1:47 PM, Geoffrey Myers wrote: Is max connections in any table in the database I can access? Not really a table, but it is selectable: show max_connections; use show all to see everything. -Andy -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make

Re: [GENERAL] Is max connections in a table somewhere?

2011-08-10 Thread Scott Marlowe
On Wed, Aug 10, 2011 at 12:47 PM, Geoffrey Myers li...@serioustechnology.com wrote: Is max connections in any table in the database I can access? No it's in the postgresql.conf file, which is in various places depending on how pg was installed. for debian / ubuntu it's in

[GENERAL] is max connections in a database table somewhere

2011-08-10 Thread Geoffrey Myers
Is the max connections value in a system table somewhere? Thanks. -- Geoffrey Myers Myers Consulting Inc. 770.592.1651 -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Is max connections in a table somewhere?

2011-08-10 Thread Guillaume Lelarge
On Wed, 2011-08-10 at 13:41 -0500, Andy Colson wrote: On 8/10/2011 1:47 PM, Geoffrey Myers wrote: Is max connections in any table in the database I can access? Not really a table, but it is selectable: show max_connections; use show all to see everything. Actually, it's also

Re: [GENERAL] Is max connections in a table somewhere?

2011-08-10 Thread Ray Stell
On Wed, Aug 10, 2011 at 02:47:25PM -0400, Geoffrey Myers wrote: Is max connections in any table in the database I can access? edbstore= \d pg_catalog.pg_settings; View pg_catalog.pg_settings Column | Type | Modifiers +-+--- name | text| setting

Re: [GENERAL] Is max connections in a table somewhere?

2011-08-10 Thread Andy Colson
On 8/10/2011 1:49 PM, Guillaume Lelarge wrote: On Wed, 2011-08-10 at 13:41 -0500, Andy Colson wrote: On 8/10/2011 1:47 PM, Geoffrey Myers wrote: Is max connections in any table in the database I can access? Not really a table, but it is selectable: show max_connections; use show all to see

Re: [GENERAL] Is max connections in a table somewhere?

2011-08-10 Thread Geoffrey Myers
Scott Marlowe wrote: On Wed, Aug 10, 2011 at 12:47 PM, Geoffrey Myers li...@serioustechnology.com wrote: Is max connections in any table in the database I can access? No it's in the postgresql.conf file, which is in various places depending on how pg was installed. for debian / ubuntu it's

Re: [GENERAL] Is max connections in a table somewhere?

2011-08-10 Thread Adrian Klaver
On Wednesday, August 10, 2011 11:47:25 am Geoffrey Myers wrote: Is max connections in any table in the database I can access? SELECT current_setting('max_connections'); current_setting - 100 -- Adrian Klaver adrian.kla...@gmail.com -- Sent via pgsql-general mailing list

Re: [GENERAL] Problem with planner

2011-08-10 Thread Cédric Villemain
2011/8/9 hubert depesz lubaczewski dep...@depesz.com: On Tue, Aug 09, 2011 at 04:08:39PM -0400, Tom Lane wrote: I suppose what's going on here is that the state and ending_tsz columns are highly correlated, such that there are lots of 'active' items but hardly any of them ended more than a day

[GENERAL] streaming replication: one problem several questions

2011-08-10 Thread Lonni J Friedman
Greetings, I've got three Linux systems (each with Fedora15-x86_64 running PostgreSQL-9.0.4). I'm attempting to get a basic streaming replication setup going with one master two standby servers. At this point, the replication portion appears to be working. I can run an 'update' statement on

Re: [GENERAL] Postgres on SSD

2011-08-10 Thread Ondrej Ivanič
Hi, 2011/8/10 Tomas Vondra t...@fuzzy.cz: On 10 Srpen 2011, 1:17, Ondrej Ivanič wrote: - What needs to be changed at Postgres/Operating system level? The obvious one is to change random_page_cost (now: 2) and seq_page_cost (now: 4). What else should I look at? Are you sure about this? I'm

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread Craig Ringer
On 11/08/2011 1:00 AM, c k wrote: I have renamed uuid-ossp.dll to 0uuid-ossp.dll in postgresql's lib directory. But it is also found that postgresql's bin directory is not included in the path. It doesn't have to be. On Windows, the directory containing the current executable is implicitly

Re: [GENERAL] is max connections in a database table somewhere

2011-08-10 Thread Greg Smith
On 08/10/2011 02:46 PM, Geoffrey Myers wrote: Is the max connections value in a system table somewhere? If you intend to do anything with the value you probably want one of these forms: SELECT CAST(current_setting('max_connections') AS integer); SELECT CAST(setting AS integer) FROM

[GENERAL] Convert mysql to postgresql

2011-08-10 Thread AI Rumman
I have to convert some mysql queries to postgresql. Is there any good tools for this task?