Re: [GENERAL] Naive schema questions

2004-05-27 Thread Nick Barr
- Original Message - From: Peter Eisentraut [EMAIL PROTECTED] To: Rory Campbell-Lange [EMAIL PROTECTED] Cc: Postgresql General List [EMAIL PROTECTED] Sent: Thursday, May 27, 2004 1:10 PM Subject: Re: [GENERAL] Naive schema questions Am Donnerstag, 27. Mai 2004 13:15 schrieb Rory

Re: [GENERAL] insert/update

2004-05-27 Thread Jeff Eckermann
--- Tom Allison [EMAIL PROTECTED] wrote: Jeff Eckermann wrote: --- Tom Allison [EMAIL PROTECTED] wrote: I seemed to remember being able to do this but I can't find the docs. Can I run a sql query to insert new or update existing rows in one query? So I have to watch out for

Re: [GENERAL] One more time on ONE-TO-MANY

2004-05-27 Thread Laura Vance
I agree with your statement. I believe that the SQL standard does not support the 3rd option by design. I could be wrong, but everything I've seen only discusses the first 2 options. If a RDBMS does that automatically, think about this possible consequence. Lets say that you have a

Re: [GENERAL] Naive schema questions

2004-05-27 Thread btober
On 5/27/2004 7:15 AM, Rory Campbell-Lange wrote: seems to suggest that the functions are schema specific. It is even better. The property that set's your schema context is called search_path. This contains a list of schema names. For an unqualified (schema name not explicitly given)

[GENERAL] custom error messages/numbers

2004-05-27 Thread BARTKO Zoltan
Folks, I am developing an app for PostgreSQL, entirely with stored functions (somewhat resembling the object-oriented approach. In fact it is not an app, just an API). All my functions return an integer value - 0 if the function was successful, another value otherwise. Until now, all

[GENERAL] Howto handle views/Rules Privileges

2004-05-27 Thread Ulrich Meis
Hi! Situation two schemas: webviews: Contains a set of views with insert rules on them, accessed via a GUI. devconf: Business logic, all the tables, functions, triggers that I want to restrict access to as far as possible.Preferably, I wouldn't even grant usage to the schema. I have a problem

Re: [GENERAL] I want to use postresql for this app, but...

2004-05-27 Thread Joshua D. Drake
So are you saying that if you connect to any GPL database (e.g. gnumed is a GPL database created with Postgresql), you must GPL your code? Even when using something like ODBC as the connection method? I don't think so. The difference is, that PostgreSQL is BSD and you are connecting from a GPL

Re: [GENERAL] custom error messages/numbers

2004-05-27 Thread Richard Huxton
BARTKO Zoltan wrote: Folks, I am developing an app for PostgreSQL, entirely with stored functions (somewhat resembling the object-oriented approach. In fact it is not an app, just an API). All my functions return an integer value - 0 if the function was successful, another value otherwise. Until

[GENERAL] Database Size Limiting

2004-05-27 Thread Campano, Troy
Title: Database Size Limiting Is there a way to limit the size that an individual database can take up? My understanding is that all your databases go into a file system which is your catalog cluster. But all the databases can grow until that filesystem is full. Is there a way to limit

Re: [GENERAL] Database Size Limiting

2004-05-27 Thread Richard Huxton
Campano, Troy wrote: Is there a way to limit the size that an individual database can take up? My understanding is that all your databases go into a file system which is your 'catalog cluster'. But all the databases can grow until that filesystem is full. Is there a way to limit how big a database

Re: [GENERAL] Database Size Limiting

2004-05-27 Thread Joshua D. Drake
Hello, You could use Filsystem quotas but I strongly suggest against it as it will probably bring about database corruption. A better solution would be to monitor the space being allocated so you can add storage as required. Sincerely, Joshua D. Drake Campano, Troy wrote: -- Is there a way to

Re: [GENERAL] Database Size Limiting

2004-05-27 Thread Campano, Troy
My understanding is databases reside within 'database clusters' in postgresql. Is this right? Can I run multiple database clusters within one postgresql/postmaster server? Then could I use filesystem quotas for each cluster? Thank you! -Original Message- From: Joshua D. Drake

Re: [GENERAL] Database Size Limiting

2004-05-27 Thread Richard Huxton
Joshua D. Drake wrote: Hello, You could use Filsystem quotas but I strongly suggest against it as it will probably bring about database corruption. I thought we handled that? I'm not saying it'd be pleasant, but I think it's no worse than a power-outage. Hmm, can't find anything in the manuals

Re: [GENERAL] Database Size Limiting

2004-05-27 Thread Richard Huxton
Joshua D. Drake wrote: Hello, You could use Filsystem quotas but I strongly suggest against it as it will probably bring about database corruption. Ah - manual reference http://www.postgresql.org/docs/current/static/disk-full.html 24.2. Disk Full Failure The most important disk monitoring task of

Re: [GENERAL] Connection log entries - random port number recorded

2004-05-27 Thread Matt Van Mater
On linux you can use lsof -i to see all current connections, I used to use something similar on Windows, but can't remember what it was. The tool you're looking for is called fport, and is distributed for free by Foundstone. It lists which program is using each open port. Alternatively you

Re: [GENERAL] [ADMIN] Clustering Postgres

2004-05-27 Thread Greg Spiegelberg
Here's the basics basically because I ran out of time and budget to actually purchase it but here's what I know. 1 day to install. Installed RedHat ES 3.0 from scratch, and the PolyServe process took perhaps 1.5 hours to install including a kernel build and system reboot. Roughly 2 hours into

[GENERAL] HOWTO: Integrating Posgresql queries into an event loop

2004-05-27 Thread Mark Harrison
HOWTO: Integrating Posgresql queries into an event loop. Mark Harrison [EMAIL PROTECTED] May 27, 2004 Problem --- The commonly used postgresql APIs will block until completed. If you are in a GUI event loop, this will block your GUI responsiveness until a query is completed. If the queries are

Re: [GENERAL] Database Size Limiting

2004-05-27 Thread Campano, Troy
Is it possible to have a database spread across two data files? So if it fills up filesystem1 then we could add a second filesystem and allow it to grow onto this second filesystem? Thanks! -Original Message- From: Richard Huxton [mailto:[EMAIL PROTECTED] Sent: Thursday, May 27, 2004

[GENERAL] pg_restore quick question

2004-05-27 Thread Sally Sally
I want to dump a database containing about five tables, each containing about 25 million records. I wanted to run pg_restore per table all at the same time. Would this have any undesirable consequences. I tried it on a smaller database and it seems to work fine. Let me know your thoughts ASAP

Re: [GENERAL] custom error messages/numbers

2004-05-27 Thread Martijn van Oosterhout
On Thu, May 27, 2004 at 06:26:53PM +0200, BARTKO Zoltan wrote: Folks, I am developing an app for PostgreSQL, entirely with stored functions (somewhat resembling the object-oriented approach. In fact it is not an app, just an API). All my functions return an integer value - 0 if the

[GENERAL] PostgreSQL Logs

2004-05-27 Thread Postgresql
What logs does postgresql produce? 1) It has transaction logs. Can it log connections? Are there other logs? 2) When I start postgresql it outputs log messages to the console. Does this also log anywhere else? What Im trying to do is find all the postgresql log files and then find a

Re: [GENERAL] Naive schema questions

2004-05-27 Thread Rory Campbell-Lange
Fabulous stuff! I am so delighted I chose Postgresql a couple of year ago. Thank you for the valuable insights. A comment or two below: On 27/05/04, Peter Eisentraut ([EMAIL PROTECTED]) wrote: Am Donnerstag, 27. Mai 2004 13:15 schrieb Rory Campbell-Lange: I imagined schemas might allow me to

Re: [GENERAL] Naive schema questions

2004-05-27 Thread Jan Wieck
On 5/27/2004 6:03 PM, Rory Campbell-Lange wrote: Just a question on this, Jan. Would one expect UNIONS for this sort of work? I just did this which is useful anyway: schematest= SELECT (select count(id) from b.messages) + (select count(id) from a.messages);

Re: [GENERAL] pg_restore quick question

2004-05-27 Thread Chris Browne
[EMAIL PROTECTED] (Sally Sally) writes: I want to dump a database containing about five tables, each containing about 25 million records. I wanted to run pg_restore per table all at the same time. Would this have any undesirable consequences. I tried it on a smaller database and it seems to

[GENERAL] How do I unsubscribe?

2004-05-27 Thread Lee Hanxue
Sorry for posting this to the list, but I tried sending a message to [EMAIL PROTECTED] with the message unsubscribe postgresql-general and I got no reply. The web interface does not seem to work either. How else can I get myself unsubscribed from this list? Thank you.

Re: [GENERAL] PostgreSQL Logs

2004-05-27 Thread Mike G
Yes to the first two questions under number 1. Not sure what you are looking for on the last one. Yes to number 2 if you configure it correctly although I don't know if it can write to a file and screen at the same time. Open the postgresql.conf file. This page in the docs might help.

Re: [GENERAL] PostgreSQL Logs

2004-05-27 Thread Postgresql
Basically, I'm looking for information on logging connections (who's connecting and when), what the users are doing when connected (creating tables, updating data, etc), and if there are any system messages (like when the postgresql server is started, stopped, if it has problems, etc). Thanks!

[GENERAL] query results different after vacuum analyze? 7.4.0

2004-05-27 Thread Klint Gore
query is select t2.field4, t1.* from t1 left outer join t2 on t2.field1 = t1.field1 and t2.field2 = t1.field2 There are 55k rows in t1 (103 fields) and 10k in t2 (4 fields, 4 is text). before vacuum analyze the query gave 10k rows like it was doing an inner join. after vacuum analyze gave

Re: [GENERAL] Naive schema questions

2004-05-27 Thread Tom Lane
[EMAIL PROTECTED] writes: And where do tables created with CREATE LOCAL TEMPORARY TABLE... fit into this, like if say a local temp table where created that has the same name as an existing normal (i.e., not a local temp) table? Temp tables live in a schema that is effectively inserted into