Re: [GENERAL] postgres and emacs on windows os

2006-09-08 Thread C.Strobl
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Thursday, September 07, 2006 2:46 AM To: pgsql-general@postgresql.org Subject: [GENERAL] postgres and emacs on windows os hi all, has anybody experience using psql with emacs (M-x sql-postgres) on

Re: [GENERAL] plz unsubscribe me

2006-09-08 Thread Csaba Nagy
Or what about automatically unsubscribing at that point? (In spite of other ways it's awful, mailman does that rather well.) ... and voila, you (and now myself) could have been unsubscribed yourself on this mail... it's not that hard to have any specific string by mistake on your subject

[GENERAL] PostgreSQL books for beginner

2006-09-08 Thread venkata rao
could you suggest good books for a beginner learning PostgreSQL database. thanks rao.a.v ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] Majordomo drops multi-line Subject:

2006-09-08 Thread Marc G. Fournier
On Thu, 7 Sep 2006, Greg Sabino Mullane wrote: As much as I dislike majordomo, I'm not seeing a strong argument here for replacing it. As far as I can tell, there are no problems with our using it: the unsubscribe-in-subject thing was added to pgsql-general and seems to be working just fine.

Re: [GENERAL] plz unsubscribe me

2006-09-08 Thread Alvaro Herrera
Andrew Sullivan wrote: On Wed, Aug 30, 2006 at 02:11:11PM -0400, Tom Lane wrote: Actually, what I'd like to see done is to get majordomo to bounce list messages containing unsubscribe in the subject, with an explanatory message about the right way to unsubscribe. There's no reason the

Re: [GENERAL] plz unsubscribe me

2006-09-08 Thread Geoffrey
Joshua D. Drake wrote: Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: So I don't think we should do anything about it. It's not really a serious problem. Actually, what I'd like to see done is to get majordomo to bounce list messages containing unsubscribe in the subject, with an

Re: [GENERAL] plz unsubscribe me

2006-09-08 Thread Geoffrey
Joshua D. Drake wrote: Actually it is quite ridiculous that we expect someone to read the mail headers. But relatively reasonable to assume that one could unsubscribe if they can figure out how to subscribe.. -- Until later, Geoffrey Those who would give up essential Liberty, to purchase

Re: [GENERAL] Database design and triggers...

2006-09-08 Thread romantercero
It just occurred to me. The purpose of normalizing the information and having it stored on two separate tables is defeated if I have another table that contains the same information but in an un-normalized fashion. I would end up with two copies of the same information, one normalized but not

Re: [GENERAL] Database design and triggers...

2006-09-08 Thread romantercero
Hi Brandon, thanks for answering. The information regarding a transaction is stored on two separate tables due to normalization. The first table stores general information regarding the transaction like Transaction number, date, customer ID, type of transaction, userID etc... The second table

Re: [GENERAL] PostgreSQL books for beginner

2006-09-08 Thread A. Kretschmer
am Thu, dem 07.09.2006, um 15:58:14 -0400 mailte venkata rao folgendes: could you suggest good books for a beginner learning PostgreSQL database. Visit our homepage and read http://www.postgresql.org/docs/books/ HTH, Andreas -- Andreas Kretschmer Kontakt: Heynitz: 035242/47215, D1:

Re: [GENERAL] PostgreSQL books for beginner

2006-09-08 Thread Rich Shepard
On Thu, 7 Sep 2006, venkata rao wrote: could you suggest good books for a beginner learning PostgreSQL database. The Douglas and Douglas book -- second edition -- is excellent as an introduction to PostgreSQL. If you want to learn SQL, any book by Joe Celko will be the best you can do. It's

Re: [GENERAL] PostgreSQL books for beginner

2006-09-08 Thread Olexandr Melnyk
On Thu, 7 Sep 2006, venkata rao wrote: could you suggest good books for a beginner learning PostgreSQL database. Although being an old book, Bruce Momjian's PostgreSQL: Introduction and Concepts can be a good start, especially for people, who haven't used SQL before.

Re: [GENERAL] pgpool on Opteron server running FreeBSD 6.0

2006-09-08 Thread Vivek Khera
On Sep 7, 2006, at 3:31 PM, andy rost wrote: a) The system load is 20 b) WCPU values for the 14 active pgpool processes exceed 20% c) Context switching on the server jumps as high as 250,000 The application now takes 4 (with pgpool) rather than less than two hours (without pgpool) to

Re: [GENERAL] Database design and triggers...

2006-09-08 Thread Brandon Aiken
Actually, I don't think you need Table 2 at all. Rather, you can fairly easily incorporate all the functionality of CurrentCountTable into Table 2 and then use a query or a VIEW. Say you have these two tables. [I'm not the best at data modeling yet, so I wouldn't necessarily take these

[GENERAL] ECPG - how to fetch then sort strings

2006-09-08 Thread Poul Jensen
I need to fetch strings from a database with ECPG and then sort them in C. Here is one of my failed attempts: ### int main(int argc, char *argv[]) { int maxlen=20; long nrec; EXEC SQL BEGIN DECLARE SECTION; varchar filenms[][maxlen]=NULL; char dbnm[50]; EXEC SQL

Re: [GENERAL] Query performance inconsistant.

2006-09-08 Thread Tom Lane
Matthew Schumacher [EMAIL PROTECTED] writes: Here is the proc that has very inconsistent (anywhere from 25ms to 8000ms) performance: ... This setup, with concurrency, is returning very inconsistent query performance. Sometimes its very fast, other times it's slow and waits. This makes me

Re: [GENERAL] ECPG - how to fetch then sort strings

2006-09-08 Thread Martijn van Oosterhout
Please don't use reply to start new thread, thanks. On Fri, Sep 08, 2006 at 05:55:44AM -0800, Poul Jensen wrote: I need to fetch strings from a database with ECPG and then sort them in C. Here is one of my failed attempts: snip varchar filenms[][maxlen]=NULL; I think you need to reread the

Re: [GENERAL] PostgreSQL books for beginner

2006-09-08 Thread Michael Schmidt
I began learning PostgreSQL a couple of years ago, having worked previously with Paradox. I would agree with a previous responder that the Douglas Douglas book "PostgreSQL: the comprehensive guide to building, programming, and administering PostgreSQL databases" 2nd ed. is a good book.

[GENERAL] Stored Procedure performance / elegance question

2006-09-08 Thread Karen Hill
x-no-archive:yes Hello. I have a stored procedure which returns a setof record. The function takes a few arguments, and if a couple of specific input values are null, it is required that the stored procedure perform different actions. I know that the planner does not store the plan when

[GENERAL] Determining right size for max_fsm_pages on large setup?

2006-09-08 Thread Francisco Reyes
Is there a way to determine the needed amount of fsm pages? I have a database that I started with 1,000,000 max_fsm_pages and I was doing vacuum analyze verboze daily. Checked every couple of days to make sure we had the right amount of fsm pages. A few days ago I noticed that we got the

Re: [GENERAL] Stored Procedure performance / elegance question

2006-09-08 Thread Merlin Moncure
On 8 Sep 2006 11:57:54 -0700, Karen Hill [EMAIL PROTECTED] wrote: I know that the planner does not store the plan when EXECUTE is used in a function, but the function looks better when the sql is created dynamically. my general rule is use static when you can, dynamic when you have to. this is

Re: [GENERAL] Determining right size for max_fsm_pages on large setup?

2006-09-08 Thread Vivek Khera
On Sep 8, 2006, at 4:29 PM, Francisco Reyes wrote: I have a database that I started with 1,000,000 max_fsm_pages and I was doing vacuum analyze verboze daily. Checked every couple of days to make sure we had the right amount of fsm pages. A few days ago I noticed that we got the notice

Re: [GENERAL] [NOVICE] Insert Only Postgresql

2006-09-08 Thread Brandon Aiken
Sure. Any RDBMS can do that. Just create a user account (login role for PostgreSQL) and only grant the INSERT privilege to them on your tables, then connect with that account with your program. Any DELETE or UPDATE statements will automatically fail. -- Brandon Aiken

Re: [GENERAL] Stored Procedure performance / elegance question

2006-09-08 Thread Karen Hill
Merlin Moncure wrote: On 8 Sep 2006 11:57:54 -0700, Karen Hill [EMAIL PROTECTED] wrote: I know that the planner does not store the plan when EXECUTE is used in a function, but the function looks better when the sql is created dynamically. my general rule is use static when you can,

Re: [GENERAL] Insert Only Postgresql

2006-09-08 Thread Karen Hill
Don't forget that one can create a DO NOTHING rules for DELETE and UPDATE in addition to the INSERT only privilege. This will prevent even the owner of the table from doing any accidental updating or deleting. Brandon Aiken wrote: Sure. Any RDBMS can do that. Just create a user account

Re: [GENERAL] Determining right size for max_fsm_pages on large

2006-09-08 Thread Francisco Reyes
Vivek Khera writes: how many actual pages of data (and index) do you have? you want to see how many relpages you're relations are using in the pg_class view. In 1 database: select relname,relpages,reltuples from pg_class order by reltuples desc limit 7; relname |

Re: [GENERAL] [NOVICE] Insert Only Postgresql

2006-09-08 Thread Merlin Moncure
On 9/8/06, Brandon Aiken [EMAIL PROTECTED] wrote: Sure. Any RDBMS can do that. Just create a user account (login role for PostgreSQL) and only grant the INSERT privilege to them on your tables, then connect with that account with your program. Any DELETE or UPDATE statements will

Re: [GENERAL] Stored Procedure performance / elegance question

2006-09-08 Thread Merlin Moncure
On 8 Sep 2006 14:39:54 -0700, Karen Hill [EMAIL PROTECTED] wrote: Merlin Moncure wrote: you could of course do: FOR rec IN SELECT * FROM test WHERE $1 is null or mydate $1 loop [...] or some such. This was a simple example. In reality, the structure of the query is altered, but there are

[GENERAL] Logging queries that are part of a stored procedure

2006-09-08 Thread Michael Nolan
Setting postgresql 8.1.3 to log all queries only logs direct queries, not ones made as part of a stored procedure (function) call.Is there a way to get it to log queries that are part of functions?--Mike Nolan

Re: [GENERAL] Logging queries that are part of a stored procedure

2006-09-08 Thread Merlin Moncure
On 9/8/06, Michael Nolan [EMAIL PROTECTED] wrote: Setting postgresql 8.1.3 to log all queries only logs direct queries, not ones made as part of a stored procedure (function) call. Is there a way to get it to log queries that are part of functions? not really, but you can 'raise notice'