[GENERAL] rotating log files

2001-04-27 Thread Jelle Ouwerkerk
Hi What is a good solution for rotating postgresql log files? I'm running 'Linux 2.2.16-22smp #1 SMP i686 unknown' and a solution that was proposed to me was to use cron and a program called logrotate: DESCRIPTION logrotate is designed to ease administration of systems that

[GENERAL] starting personal postmaster

2001-04-27 Thread Stefan Karrmann
How can I start a personal postmaster, e.g. the postmaster should manage a database cluster in ~/pgdata/. I'm using the Debian package of postgresql (7.0.3) and it want's to create a socket at /var/run/postgres/.s.PORT.sock (or something similiar). As I am not user postgres I dont have the

Re: [GENERAL] last comma inside CREATE TABLE () statements

2001-04-27 Thread Rod Taylor
Heh.. Actually, those queries look quite good if you centre them in a page -- Assuming all characters are the same width anyway. SELECT, FROM, and other key words go onto the left column along with comma's, and the relevant database columns, tables, and where clauses go on the right. With a

Re: [GENERAL] Re: Re: Need for newbie friendly docs (was Newbie struggling...)

2001-04-27 Thread Clayton Vernon
Joel- In all fairness, there aren't any good HTML-based Unix tutorials. I've looked for them. In particular, Sun is worthless here, curious since their Java tutorial is (IMO) really well done. I'm hoping PostgreSQL is MORE stable than Oracle in our Solaris environment. The massive CPU/disk

Re: [GENERAL] JDBC and Accents

2001-04-27 Thread Marko Kreen
On Fri, Apr 27, 2001 at 02:36:21PM +0200, Loïc Courtois wrote: On Fri, Apr 27, 2001 at 01:56:38AM +0200, Loïc Courtois wrote: Hello, I have some problems to display the accents in my db, using the JDBC and postgres 7.1. Apparently, all accents are replaced by a '?'. What

[GENERAL] Returning tuple(s) from C-Functions

2001-04-27 Thread Philip Poten
Hi. I'm into programming a function for pg for searching a ldap directory. But this whole effort has absolutely no sense, if i don't find a way to return _at least_ one whole tuple from a C-Function, e.g. create function foobar(footable) returns bartable as

[GENERAL] caching/ virtual file systems

2001-04-27 Thread Clayton Vernon
A newbie question as I prepare to dive into this: Under $PGDATA, can I expect to see subdirectories emerge within databases, say for INDICES, TABLES, etc? The reason: On Solaris, I have some RAM in /tmp I want to employ as a virtual file system to increase the performance of PG. I've

[GENERAL] Re: I am now Linux and PostgreSQL user, have a question

2001-04-27 Thread Joel Burton
On Fri, 27 Apr 2001, Isiah Thomas wrote: I read some docunment say that to start the postgres service must type this command /etc/rc.d/init.d/postgres start That's pretty specific to RedHat and RedHat-derived systems. (And then, only if you install PostgreSQL from the RPMs, which if you're

Re: [GENERAL] SQL Where LIKE - Range it!

2001-04-27 Thread Frank Bax
select * from table where last_name ~ '^[A-F]'; or select * from table where last_name between 'A' and 'G'; or select * from table where last_name ='A' and last_name'G' The second one is broken if last_name='G' returns something. Use ~* in first example to ignore case.

Re: [GENERAL] Re: Report Writer for PostgreSQL

2001-04-27 Thread larry a price
From: Patrick Lanphier [EMAIL PROTECTED] snip Well it needs the capability format data on many different graph, capable of generating HTML, PDF, and RTF formats. The server will be running on Linux but the design platform can be whatever. The problem I had with one report writer

[GENERAL] Re: SQL Where LIKE - Range it!

2001-04-27 Thread Joel Burton
On Thu, 26 Apr 2001, Steagus wrote: What I'd like to do is pull a list of records where there is a range of last names; say from A - F. select * from table where last_name LIKE 'A%' AND last_name LIKE 'F%' - for example. The above code I've tried for this doesn't seem to work as I'd

[GENERAL] Re: SQL Where LIKE - Range it!

2001-04-27 Thread Gregory Wood
What I'd like to do is pull a list of records where there is a range of last names; say from A - F. select * from table where last_name LIKE 'A%' AND last_name LIKE 'F%' - for example. The above code I've tried for this doesn't seem to work as I'd expect it too? When you use the AND

Re: [GENERAL] starting personal postmaster

2001-04-27 Thread Peter Eisentraut
Stefan Karrmann writes: How can I start a personal postmaster, e.g. the postmaster should manage a database cluster in ~/pgdata/. I'm using the Debian package of postgresql (7.0.3) and it want's to create a socket at /var/run/postgres/.s.PORT.sock (or something similiar). As I am not user

[GENERAL] rotating log files

2001-04-27 Thread Jelle Ouwerkerk
I think I may have found an answer to my own problem: What is a good solution for rotating postgresql log files? I'm running 'Linux 2.2.16-22smp #1 SMP i686 unknown' and a solution that was proposed to me was to use cron and a program called logrotate: Unfortunately, after

Re: [GENERAL] SQL Where Like - Range it?!

2001-04-27 Thread Len Morgan
What I'd like to do is pull a list of records where there is a range of last names; say from A - F. select * from table where last_name LIKE 'A%' AND last_name LIKE 'F%' - for example. The above code I've tried for this doesn't seem to work as I'd expect it too? SELECT * FROM table WHERE

Re: [GENERAL] rotating log files

2001-04-27 Thread Peter Eisentraut
Jelle Ouwerkerk writes: I'm running 'Linux 2.2.16-22smp #1 SMP i686 unknown' and a solution that was proposed to me was to use cron and a program called logrotate: Unfortunately, after replacing/rotating/compressing the database log file, the new log file remains empty. I have a feeling

Re: [GENERAL] creating constants in postgres

2001-04-27 Thread Peter Eisentraut
Thomas F. O'Connell writes: is there in postgres a way to create a constant like CURRENT_DATE for general use? Those things are just functions with a special syntax. No, it's not easily possible to create more such functions, but it's easy to create regular functions. -- Peter Eisentraut

Re: [GENERAL] caching/ virtual file systems

2001-04-27 Thread Peter Eisentraut
Clayton Vernon writes: A newbie question as I prepare to dive into this: Under $PGDATA, can I expect to see subdirectories emerge within databases, say for INDICES, TABLES, etc? The layout (in 7.1) is $PGDATA/base/oid of database/oid of table,index... The reason: On Solaris, I have

Re: [GENERAL] Re: I am now Linux and PostgreSQL user, have a question

2001-04-27 Thread Steve Wampler
Joel Burton wrote: On Fri, 27 Apr 2001, Isiah Thomas wrote: I read some docunment say that to start the postgres service must type this command /etc/rc.d/init.d/postgres start That's pretty specific to RedHat and RedHat-derived systems. (And then, only if you install PostgreSQL

[GENERAL] Re: running pgaccess on localhost

2001-04-27 Thread Joel Burton
On Fri, 27 Apr 2001, Mike Goetz wrote: Hello, pgsql newbie here... I'm trying to run pgaccess on a database I've created, and I get the following error: PostgreSQL error message: Connection to database failed PQconnectPoll() -- connect() failed: Connection refused Is the postmaster

[GENERAL] General usage for pg_dumpall

2001-04-27 Thread Joseph Koenig
Hi, I want to backup a database. I've read here that pg_dumpall is really the best way to do it. However, what options are going to be most useful to me, should I need to restore the db ever. I know there's probably lots of conditional things, but just in general, what are the most commonly used.

Re: [GENERAL] rotating log files

2001-04-27 Thread Warren Vanichuk
# start /var/log/postgresql.log { compress rotate 10 create 0664 postgres postgres size=1k weekly sharedscripts postrotate /etc/rc.d/init.d/postgresql restart endscript }

[GENERAL] pg_encoding

2001-04-27 Thread Michelle Murrain
Hi folks, I'm upgrading from Postgres 6.5 to 7.1. 6.5 was originally installed using apt-get (this is on a debian potato box). I'm installing 7.1 from tarball, because there are some particular things I want. Anyway, I'm dumping my database, and I get the command: pg_encoding: command not

[GENERAL] ON DELETE Behavior after the fact

2001-04-27 Thread John Pagakis
I have a database in production that requires some ON DELETE behavior. Is there a way to use ALTER TABLE to define ON DELETE behavior for the foreign keys, or will I have to write triggers at this point? ___ John Pagakis DevelopOnline.com

[GENERAL] PostgreSQL and mySQL database size question

2001-04-27 Thread Fred Ingham
To all, Before I begin, this is NOT a PostgreSQL verses mySQL post. I have used both databases and have found both of these products to be excellent choices depending on the specific requirements for a given project. That said, I am trying to understand the database size differences between

RE: [GENERAL] PostgreSQL and mySQL database size question

2001-04-27 Thread Fred Ingham
Bruce, I have your book right in front of me... do you have that information in the book? If not, I will take a look at the FAQ. As for mySQL, here are the storage requirements: Storage requirements for numeric types Column type Storage required TINYINT 1 byte SMALLINT

Re: [GENERAL] ON DELETE Behavior after the fact

2001-04-27 Thread Stephan Szabo
On Fri, 27 Apr 2001, John Pagakis wrote: I have a database in production that requires some ON DELETE behavior. Is there a way to use ALTER TABLE to define ON DELETE behavior for the foreign keys, or will I have to write triggers at this point? The easiest thing is probably to drop the

Re: [GENERAL] PostgreSQL and mySQL database size question

2001-04-27 Thread Bruce Momjian
Did you see the FAQ items on estimating database sizes? Does MySQL have less overhead per row? [ Charset ISO-8859-1 unsupported, converting... ] To all, Before I begin, this is NOT a PostgreSQL verses mySQL post. I have used both databases and have found both of these products to be

Re: [GENERAL] PostgreSQL and mySQL database size question

2001-04-27 Thread Bruce Momjian
FAQ item 4.7 discusses table size computations. My guess is that it is the 36 bytes-per-row that is the problem. Those bytes record the visibility of the row for proper transactions semantics and MVCC. Bruce, I have your book right in front of me... do you have that information in the

RE: [GENERAL] PostgreSQL and mySQL database size question

2001-04-27 Thread Fred Ingham
OK, but that only accounts for 3.2MB of the extra 49.6MB used by PostgreSQL. -Original Message- From: Bruce Momjian [mailto:[EMAIL PROTECTED]] Sent: Friday, April 27, 2001 2:05 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: [GENERAL] PostgreSQL and mySQL database size

[GENERAL] WAL Log using all my disk space!

2001-04-27 Thread webb sprague
Hi all, The problem: I do a large bulk copy once a day (100,000 records of Radius data), tearing down indices, truncating a large table that contains summary information, and rebuilding everything after the copy. Over the course of this operation, I can generate up to 1.5 gigs of WAL data in

[GENERAL] Help, I dropped a system datatype, and now I'm ....

2001-04-27 Thread Dave Cramer
Hi, I inadvertantly dropped a system data type (box) and now I am getting errors cannot find datatype oid 603 when I do some selects I have two possible solutions; 1 of which doesn't work yet insert back into the pg_type table the box row copied from another machine with oid 603, which