Re: [GENERAL] Need input on postgres used for phpBB

2005-05-11 Thread Jerome Macaranas
On Tuesday 10 May 2005 22:00, Scott Marlowe wrote: > On Mon, 2005-05-09 at 23:35, Jerome Macaranas wrote: > > i didnt set fsm... the config i paste is all that i put into place... > > OK, that's likely a part of your problem. > > Did you run the vacuumdb -af I recommended? Did it help? If so, you

[GENERAL] Collation problem

2005-05-11 Thread Andrei Gaspar
Hi all, I have a table TranslationDictionary in a database initalized with lc_collation and lc_type de-de . In the table is the value 'Straße' and I can't insert 'Strasse', but when I try to create a foreign key on this table, the value 'Strasse' in the foreign table is unmatched. Is this a bug,

Re: [GENERAL] Need to determine how badly tables need vacuuming

2005-05-11 Thread Tom Lane
Marc Munro <[EMAIL PROTECTED]> writes: > Is there a query that will return an estimated row count as well as an > estimated unused tuple count for each table? See the contrib/pgstattuple module. regards, tom lane ---(end of broadcast)--

Re: [GENERAL] Need to determine how badly tables need vacuuming

2005-05-11 Thread elein
http://www.varlena.com/GeneralBits/107.php has an explanation of the statistics views pg_stat*. Perhaps those would help. --elein [EMAIL PROTECTED] On Wed, May 11, 2005 at 04:12:11PM -0700, Marc Munro wrote: > On a 7.3 production system with limited downtime available, we can > rarely take the t

[GENERAL] Need to determine how badly tables need vacuuming

2005-05-11 Thread Marc Munro
On a 7.3 production system with limited downtime available, we can rarely take the time to run vaccuum full. From time to time though, performance of some of the tables becomes an issue and we have to perform a full vaccum on those tables. We'd like to be able to better plan these operations, so:

Re: [ADMIN] [GENERAL] Storing database in WORM devices

2005-05-11 Thread Tom Lane
[EMAIL PROTECTED] writes: > Tom Lane suggested a vacuum freeze (? or something like that) for archival > read only data. I got the impression the template databases are freeze > dried for freshness (good to the last bit?) That feature might help as > well in the transition from read-write to read

Re: [GENERAL] grant all privileges to all tables in a database

2005-05-11 Thread Robert Treat
On Thursday 14 April 2005 00:33, Florin Andrei wrote: > On Mon, 2005-04-11 at 03:28 +0200, Daniel Verite wrote: > > Florin Andrei wrote: > > > On MySQL, it's enough to do this: > > > > > > GRANT ALL PRIVILEGES ON dbname.* TO username [IDENTIFIED BY > > > 'password']; > > > > > > On PostgreSQL, you

Re: [ADMIN] [GENERAL] Storing database in WORM devices

2005-05-11 Thread Juan Miguel Paredes
I know it would be a hard approach but... perhaps ON DELETE and ON UPDATE triggers would help? On 5/11/05, Jay A. Kreibich <[EMAIL PROTECTED]> wrote: On Wed, May 11, 2005 at 03:51:43PM -0400, [EMAIL PROTECTED] scratched on the wall: > I would like to clarify something.> I intend to create the datab

Re: [ADMIN] [GENERAL] Storing database in WORM devices

2005-05-11 Thread Richard_D_Levine
Tom Lane suggested a vacuum freeze (? or something like that) for archival read only data. I got the impression the template databases are freeze dried for freshness (good to the last bit?) That feature might help as well in the transition from read-write to read-only. Rick

Re: [ADMIN] [GENERAL] Storing database in WORM devices

2005-05-11 Thread Jay A. Kreibich
On Wed, May 11, 2005 at 03:51:43PM -0400, [EMAIL PROTECTED] scratched on the wall: > I would like to clarify something. > I intend to create the database on a re-writable device (not WORM). > At some point, when I no longer want to add/modify the database, I > plan to copy it to the WORM device. T

Re: [GENERAL] Storing database in WORM devices

2005-05-11 Thread Alex Turner
If you simply put your database tables in their own tablespace, then move that tablespace to a WORM device, I can't see why that wouldn't work as long as you keep all the system tables etc.. on the regular RW tablespace Alex Turner netEconomist On 5/11/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wr

Re: [GENERAL] Hosting options on Postgres - what's best?

2005-05-11 Thread Peter Wilson
Just Someone wrote: Hi, I'm looking into creating a hosted application with Postgres as the SQL server. I would like to get some ideas and oppinions about the different ways to separate the different clients, using postgres. The options I had in mind: 1) Create a different database per cl

Re: [GENERAL] Storing database in WORM devices

2005-05-11 Thread GGoshen
I would like to clarify something. I intend to create the database on a re-writable device (not WORM). At some point, when I no longer want to add/modify the database, I plan to copy it to the WORM device. Then I would like to be able to access the database on the WORM device for reading purpose

Re: [ADMIN] [GENERAL] Storing database in WORM devices

2005-05-11 Thread Richard_D_Levine
Isn't there some way to trick PostgreSQL with a RAM disk, like for the WAL? Rick [EMAIL PROTECTED] wrote on 05/11/2005 02:31:55 PM: > Why? Any specific reason that you are aware of ? > Are there any writes done to the database when read only SQL > statements are issued? > > > -Original Messa

Re: [GENERAL] Storing database in WORM devices

2005-05-11 Thread Alex Turner
I think simply initialising the system causes writes in the system tables and the WAL... I'm sure someone more knowledgeable can chime in. Alex. Turner netEconomist On 5/11/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > Why? Any specific reason that you are aware of ? > Are there any writes

Re: [GENERAL] Storing database in WORM devices

2005-05-11 Thread GGoshen
Why? Any specific reason that you are aware of ? Are there any writes done to the database when read only SQL statements are issued? -Original Message- From: Douglas McNaught [mailto:[EMAIL PROTECTED] Sent: Wednesday, May 11, 2005 2:51 PM To: Goshen, Galit Cc: pgsql-general@postgresql.

Re: [GENERAL] Storing database in WORM devices

2005-05-11 Thread Douglas McNaught
<[EMAIL PROTECTED]> writes: > I would like to store the complete database into a WORM device (Write Once > Read Many). I would like to access this database directly from the WORM > device and perform read only SQL statements against this device. > > Does anyone have such installation, or can det

Re: [GENERAL] Trigger that spawns forked process

2005-05-11 Thread Tom Lane
Christopher Murtagh <[EMAIL PROTECTED]> writes: > So, if I made a slight modification to my script to this instead: > CREATE or REPLACE function exec_test() returns void as ' > unless (defined ($pid=fork)) { > die "cannot fork: $!"; > } > unless ($pid) { > $cmd="/path/to/some/script.pl";

Re: [GENERAL] UPDATE Inserts New Rows

2005-05-11 Thread Ruben Oliveira
Thanks for the answer Richard and my apologies for wasting your time. After doing the first select I found that the software that uses this database was alreading doing the inserts if there wasn't any row with a PK on it ... so every UPDATE i did worked when I expected otherwise... I only noticed

[GENERAL] Storing database in WORM devices

2005-05-11 Thread GGoshen
I would like to store the complete database into a WORM device (Write Once Read Many). I would like to access this database directly from the WORM device and perform read only SQL statements against this device.   Does anyone have such installation, or can determine if this is possible?   Ga

Re: [GENERAL] Trigger that spawns forked process

2005-05-11 Thread Christopher Murtagh
On Wed, 2005-05-11 at 00:08 +0200, Martijn van Oosterhout wrote: > On Tue, May 10, 2005 at 05:31:56PM -0400, Christopher Murtagh wrote: > > > I'm not sure what happens when you do "exit" here, but I'll lay odds > > > against it being exactly the right things. > > > > It ends the daemonized proces

Re: [GENERAL] how to calculate checkpoint_segments

2005-05-11 Thread Tom Lane
Himanshu Baweja <[EMAIL PROTECTED]> writes: > i am trying to optimise postgres 8 running on a system is there any way > to know how wht should be the value of checkpoint_segments... Enough so you usually aren't checkpointing more often than is specified by checkpoint_timeout. If you do not k

Re: [GENERAL] Disabling Triggers

2005-05-11 Thread Alban Hertroys
Mark Borins wrote: I am creating a system where I have a trigger on three different tables. There is a particular Boolean field in each of these tables that when it is set in table it should be set the same in the other two. So I figured I could put a trigger on each table that when the Bool

Re: [GENERAL] alter table owner doesn't update acl information

2005-05-11 Thread Tom Lane
"Madeleine Theile" <[EMAIL PROTECTED]> writes: > After I've dropped one of the superusers that created and thus > owns some of the views and reinstalled it again with a different usesysid So reinstall it with the same usesysid --- that's why the option exists to specify sysid in CREATE USER. Ther

Re: [GENERAL] Disabling Triggers

2005-05-11 Thread Mark Borins
That looks like a good solution. And that way it won't cascade. Thanks -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Richard Huxton Sent: May 11, 2005 11:53 AM To: Mark Borins Cc: pgsql-general@postgresql.org Subject: Re: [GENERAL] Disabling Triggers M

Re: [GENERAL] Note: Compiling on Windows with free Microsoft compilers

2005-05-11 Thread Bruce Momjian
I have taken your information, added a Borland download URL, and added it to our documentation: http://candle.pha.pa.us/main/writings/pgsql/sgml/install-win32.html Thanks. --- Brian K Boonstra wrote: > All > > Tho

Re: [GENERAL] JOIN on set of rows?

2005-05-11 Thread Tom Lane
Peter Fein <[EMAIL PROTECTED]> writes: > Sorry, I kinda wrote that wrong. ;) What I really want is: > SELECT rows of known, app-generated (app_name, app_id) > INTERSECT > SELECT t1.symbol AS app_name, t2.outside_key AS app_id > FROM t2 LEFT JOIN t1 ON t1.t2_id=t2.id > There are around a max of 50

Re: [GENERAL] Disabling Triggers

2005-05-11 Thread Richard Huxton
Mark Borins wrote: I am creating a system where I have a trigger on three different tables. There is a particular Boolean field in each of these tables that when it is set in table it should be set the same in the other two. Just make sure you only check the boolean value too: -- Trigger on table a

Re: [GENERAL] JOIN on set of rows?

2005-05-11 Thread Richard Huxton
Peter Fein wrote: SELECT t1.symbol AS app_name, t2.outside_key AS app_id FROM t2 LEFT JOIN t1 ON t1.t2_id=t2.id AS my_join LEFT JOIN rows of arbitrary (app_name, app_id) ON my_join.app_name=rows.app_name AND my_join.app_id=rows.app_id Sorry, I kinda wrote that wrong. ;) What I really want is: SELE

Re: [GENERAL] Disabling Triggers

2005-05-11 Thread Tom Lane
"Mark Borins" <[EMAIL PROTECTED]> writes: > Does anyone know if it is possible to run an update statement on a table and > for only that statement disable the trigger on the table? No, but why fire the update if not needed? Make the trigger do something like UPDATE foo SET boolcol = true

[GENERAL] how to calculate checkpoint_segments

2005-05-11 Thread Himanshu Baweja
i am trying to optimise postgres 8 running on a system is there any way to know how wht should be the value of checkpoint_segments...   i always keep fync = false since my server is fully reliable   increasing checkpoint_segments degrade the performace while checkpointing as it will have a

Re: [GENERAL] Disabling Triggers

2005-05-11 Thread Mark Borins
Thank you for the response. While the TIMESTAMP solution is a good idea. I was wondering if anyone knew of a SQL like instruction that could be called. Like: UPDATE table SET WHERE NO TRIGGERS Or something like that, however, I realize I may just be dreaming. Mark ___

Re: [GENERAL] Disabling Triggers

2005-05-11 Thread Franco Bruno Borghesi
You could add a TIMESTAMP field on the three tables (lets call it last_change), and modify your triggers to update this value every time a row is updated. Then your trigger should update the boolean fields with the boolean value of the row with the max(last_change) in the three tables, only if the

Re: [GENERAL] alter table owner doesn't update acl information

2005-05-11 Thread Bruce Momjian
Madeleine Theile wrote: > Hi, > > first of all: > I use Postgres-version: 7.3.9 and uname -a gives: > Linux 2.4.21-286-smp4G > > Now here's the problem: > I have several superusers in my database and some normal users that only > have access to the data by views. > > After I've dropped one of th

Re: [GENERAL] JOIN on set of rows?

2005-05-11 Thread Peter Fein
On 05/11/05 08:22 AM CDT, Richard Huxton said: > Peter Fein wrote: > > Hiya- > > > > I need to do something like this: > > > > SELECT t1.symbol AS app_name, t2.outside_key AS app_id > > FROM t2 LEFT JOIN t1 ON t1.t2_id=t2.id AS my_join > > LEFT JOIN rows of arbitrary (app_name, app_id) ON > > my

[GENERAL] alter table owner doesn't update acl information

2005-05-11 Thread Madeleine Theile
Hi, first of all: I use Postgres-version: 7.3.9 and uname -a gives: Linux 2.4.21-286-smp4G Now here's the problem: I have several superusers in my database and some normal users that only have access to the data by views. After I've dropped one of the superusers that created and thus owns some o

[GENERAL] Disabling Triggers

2005-05-11 Thread Mark Borins
I am creating a system where I have a trigger on three different tables.  There is a particular Boolean field in each of these tables that when it is set in table it should be set the same in the other two.   So I figured I could put a trigger on each table that when the Boolean field was

Re: [PERFORM] [GENERAL] "Hash index" vs. "b-tree index" (PostgreSQL

2005-05-11 Thread Neil Conway
Tom Lane wrote: Performance? I'll run some benchmarks tomorrow, as it's rather late in my time zone. If anyone wants to post some benchmark results, they are welcome to. I disagree completely with the idea of forcing this behavior for all datatypes. It could only be sensible for fairly wide valu

Re: [PERFORM] [GENERAL] "Hash index" vs. "b-tree index" (PostgreSQL

2005-05-11 Thread Greg Stark
Neil Conway <[EMAIL PROTECTED]> writes: > I'm posting mainly because I wasn't sure what to do to avoid false positives > in > the case of hash collisions. In the hash AM code it is somewhat awkward to > fetch the pointed-to heap tuple and recheck the scankey.[1] I just did the > first thing that

Re: [GENERAL] Fixing a too long column value in a before insert

2005-05-11 Thread Csaba Nagy
Searching the archives lead me to this link: http://archives.postgresql.org/pgsql-general/2001-10/msg01208.php (I also searched before asking but for the wrong keywords...) Is that advice still valid ? I will try in any case :-) Thanks, Csaba. On Wed, 2005-05-11 at 15:44, Tom Lane wrote: > Csa

Re: [PERFORM] [GENERAL] "Hash index" vs. "b-tree index" (PostgreSQL

2005-05-11 Thread Tom Lane
Neil Conway <[EMAIL PROTECTED]> writes: > Greg Stark wrote: >> What if the hash index stored *only* the hash code? > Attached is a WIP patch that implements this. Performance? > I'm posting mainly because I wasn't sure what to do to avoid false > positives in the case of hash collisions. In the

Re: [GENERAL] SECURITY RELEASES: 7.2.8 - 7.3.10 - 7.4.8 - 8.0.3

2005-05-11 Thread Thomas F.O'Connell
I've updated my Perl script to accommodate the version of the procedures in the final release notes: http://www.sitening.com/postgresql-update-2005-1 -tfo -- Thomas F. O'Connell Co-Founder, Information Architect Sitening, LLC Strategic Open Source: Open Your i™ http://www.sitening.com/ 110 30th A

Re: [GENERAL] Fixing a too long column value in a before insert trigger or rule

2005-05-11 Thread Tom Lane
Csaba Nagy <[EMAIL PROTECTED]> writes: > We have a situation where a varchar column was limited to a too small > maximum length in the design phase... shit happens, we will fix our db > schema in our next database downtime or software version deployment, > whichever comes first (we are using 7.4 an

Re: [GENERAL] SECURITY RELEASES: 7.2.8 - 7.3.10 - 7.4.8 - 8.0.3

2005-05-11 Thread Tom Lane
Douglas McNaught <[EMAIL PROTECTED]> writes: > Tom Lane <[EMAIL PROTECTED]> writes: >> Also, note that that message was the zero-day-security-problem response >> to the issue, and that we since figured out cleaner responses. If you >> haven't yet implemented this in your own DBs, I would suggest f

Re: [GENERAL] Fixing a too long column value in a before insert trigger or rule

2005-05-11 Thread Douglas McNaught
Csaba Nagy <[EMAIL PROTECTED]> writes: > Hi all, > > We have a situation where a varchar column was limited to a too small > maximum length in the design phase... shit happens, we will fix our db > schema in our next database downtime or software version deployment, > whichever comes first (we are

Re: [GENERAL] Rekall for Free

2005-05-11 Thread Bob
I can't wait! On 5/11/05, John Dean <[EMAIL PROTECTED]> wrote: HiThis is my first post to this mailing list. I would like all list membersthat I am the same person who used to work for MySQL AB. Even though I worked for MySQL AB, PostgreSQL has always been my RDBMS of choice. Thereason for telling

Re: [GENERAL] UPDATE Inserts New Rows

2005-05-11 Thread Richard Huxton
Ruben Oliveira wrote: I'm having an unexpected behavior from an UPDATE query : I expected only updates to existing rows but it is INSERTING new rows when there isn't a PK Hmm - doesn't sound likely. Especially if you don't supply a primary key. There are no triggers,views or rules associated with

[GENERAL] plpython setof row

2005-05-11 Thread Mage
Hello, how can I return setof rows in plpython language? I read the manual and couldn't find. Mage ---(end of broadcast)--- TIP 9: the planner will ignore your desire to choose an index scan if your joining column's datatypes

[GENERAL] PsqlODBC / Unix

2005-05-11 Thread Patrick . FICHE
Hi,   I'm using psqlodbc-08.00.0101 distribution with libiodbc-3.51.2 on Solaris with PosgreSQL 8.0.2.   Each time I want to use an ODBC application using psqlodbc, I get the following message : [iODBC][Driver Manager]ld.so.1: iodbctest: fatal: relocation error: file /usr/local/lib/psqlodb

[GENERAL] UPDATE Inserts New Rows

2005-05-11 Thread Ruben Oliveira
I'm having an unexpected behavior from an UPDATE query : I expected only updates to existing rows but it is INSERTING new rows when there isn't a PK There are no triggers,views or rules associated with the tables and to make things worse I have a similar query to another table where the UPD

[GENERAL] Rekall for Free

2005-05-11 Thread John Dean
Hi This is my first post to this mailing list. I would like all list members that I am the same person who used to work for MySQL AB. Even though I worked for MySQL AB, PostgreSQL has always been my RDBMS of choice. The reason for telling you all about about my involvement with MySQL is because

Re: [GENERAL] SECURITY RELEASES: 7.2.8 - 7.3.10 - 7.4.8 - 8.0.3

2005-05-11 Thread Douglas McNaught
Tom Lane <[EMAIL PROTECTED]> writes: > Neil Conway <[EMAIL PROTECTED]> writes: >> http://www.postgresql.org/about/news.315 > > Also, note that that message was the zero-day-security-problem response > to the issue, and that we since figured out cleaner responses. If you > haven't yet implem

[GENERAL] Fixing a too long column value in a before insert trigger or rule

2005-05-11 Thread Csaba Nagy
Hi all, We have a situation where a varchar column was limited to a too small maximum length in the design phase... shit happens, we will fix our db schema in our next database downtime or software version deployment, whichever comes first (we are using 7.4 and on the fly column type change is onl

Re: [GENERAL] JOIN on set of rows?

2005-05-11 Thread Richard Huxton
Peter Fein wrote: Hiya- I need to do something like this: SELECT t1.symbol AS app_name, t2.outside_key AS app_id FROM t2 LEFT JOIN t1 ON t1.t2_id=t2.id AS my_join LEFT JOIN rows of arbitrary (app_name, app_id) ON my_join.app_name=rows.app_name AND my_join.app_id=rows.app_id The arbitrary app_name,

[GENERAL] lazarus/zeos - installation ?

2005-05-11 Thread Zlatko Matic
I have installed lazarus. A have also downloaded zeos library, but don't know how to install it. What am I suppsoed to do? Thanks. ---(end of broadcast)--- TIP 4: Don't 'kill -9' the postmaster