Re: [GENERAL] Raid and tablespaces configuration

2005-06-27 Thread Michael Ben-Nes
You sure there are 5 HD ? Raid 10 suppose to have 4 HD Raid 0 suppose to have 2 HD Total of 6 ?? Any way Raid 0 is fast but give no reability. i prefer raid 1 or 10. Himanshu Baweja wrote: Currently my server has two raid controllers both with 5 disks attached:: On raid1: i have the

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Janning Vygen
Am Montag, 27. Juni 2005 01:40 schrieb CSN: If I have a table of items with latitude and longitude coordinates, is it possible to find all other items that are within, say, 50 miles of an item, using the geometric functions

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Uwe C. Schroeder
in the where clause use something like (requires the earthdistance contrib to be installed): geo_distance(point([origin longitude],[origin latitude]),point([target longitude column],[target latitude column])))::int = 50 On Sunday 26 June 2005 04:40 pm, CSN wrote: If I have a table of items

[GENERAL] vacuum error

2005-06-27 Thread Ulrich Wisser
Hi, after months of flawless operation I get the following error when running VACUUM ANALYZE vacuumdb: vacuuming database CLIX2 vacuumdb: vacuuming of database CLIX2 failed: ERROR: left link changed unexpectedly System: Fedora Core 2, 2.6.10-1.771_FC2 Postgres 7.4.2 What does

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Oleg Bartunov
How big is your data ? There are rather sophisticated and very effective methods in astronomy. For example, http://www.sai.msu.su/~megera/oddmuse/index.cgi/SkyPixelization, http://www.sai.msu.su/~megera/oddmuse/index.cgi/pg_sphere Oleg On Mon, 27 Jun 2005, Janning Vygen wrote: Am

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Alban Hertroys
Uwe C. Schroeder wrote: in the where clause use something like (requires the earthdistance contrib to be installed): geo_distance(point([origin longitude],[origin latitude]),point([target longitude column],[target latitude column])))::int = 50 I don't suppose geo_distance really returns

Re: [GENERAL] automating backup ?

2005-06-27 Thread Marco Colombo
On Sun, 2005-06-26 at 11:18 +0200, Zlatko Matic wrote: How to automate backup, so that Postgres automatically backups, for example, once in a week ? The same question about vacuum ? Concerning backup, how to prevent that someone makes a copy (for example pg_dumpall) of a database,

Re: [GENERAL] How to compare the schemas ?

2005-06-27 Thread Milorad Poluga
DB Comparer tool seems very useful. Thank you for your suggestions and links. Milorad Poluga                         HK CORES Beograd, Makenzijeva 31 [EMAIL PROTECTED]               +381-11-30-80-461               ---(end of broadcast)---

[GENERAL] number of records returned by cursors

2005-06-27 Thread Zac
Hi, does anyone know if there is a way (in plpgsql) to obtain the number of records returned by a cursor without fetching them all? Using FOUND and GET DIAGNOSTICS row_count variables doesn't help me: the only way seems to be fetching all the records. I try to explain it better: CREATE OR

Re: [GENERAL] automating backup ?

2005-06-27 Thread Andreas
Zlatko Matic schrieb: Thanks Fuhr. Anybody can tell me how to do it on Windows XP ? Thanks. That's again a pure Windows issue, but not commonly needed. I guess, it should be in the Windows PG-FAQ, too. I'll describe the way you go with Windows 2000. If you are lucky WinXP Pro does it the

Re: [GENERAL] Postmaster Out of Memory

2005-06-27 Thread Jeff Gold
Tom Lane wrote: Found it --- the actual leak is in index_create, not in TRUNCATE or CLUSTER at all; and it's been there a really long time. Patch for 7.4 branch attached. Excellent! Does index_create refer to something that is invoked as a consequence of CREATE INDEX? I'm looking through

[GENERAL] Web application development on Win32, deployment on Linux

2005-06-27 Thread Joe Abbate
I currently maintain a website which is deployed on LAMP, but it is developed on Windows (WAMP?). I'm considering moving both to use PostgreSQL. I'm curious as to whether others are following a similar development/deployment model and if so, what pitfalls/gotchas they have found. For

Re: [GENERAL] Win32 users?

2005-06-27 Thread Marco Colombo
On Sun, 2005-06-26 at 10:59 -0700, Bob Pawley wrote: I'll date myself so you all may know from where I am coming. My first lesson in binary math took place in a classroom in 1958. Since then I have witnessed a lot that has since swept under the bridge. This thread reminds me of the

[GENERAL] Windows XP installation problem

2005-06-27 Thread Marek Aleksander Dąbek
Hello! I'm trying to install postgresql on WindowsXP box using postgresql-8.0.msi. The installation goes fine until running the service. I get a message saying that postgre-8.0 failed to run as a service. I checked system log and came across an error saying that: PostgreSQL Database Server 8.0

Re: [GENERAL] Web application development on Win32, deployment on Linux

2005-06-27 Thread Magnus Hagander
I currently maintain a website which is deployed on LAMP, but it is developed on Windows (WAMP?). I'm considering moving both to use PostgreSQL. I'm curious as to whether others are following a similar development/deployment model and if so, what pitfalls/gotchas they have found. For

Re: [GENERAL] Windows XP installation problem

2005-06-27 Thread Magnus Hagander
Hello! I'm trying to install postgresql on WindowsXP box using postgresql-8.0.msi. The installation goes fine until running the service. I get a message saying that postgre-8.0 failed to run as a service. I checked system log and came across an error saying that: PostgreSQL Database

Re: [GENERAL] MacOSX, fink, missing readline/readline.h

2005-06-27 Thread Kevin Murphy
Teunis Peters wrote: This has to do with building postgresql-8.0.3 I'm installing on a MacOSX system (10.3) and configure's failing to find the readline installation. Installing the vanilla readline library from source now works great on 10.3. If you first install this using the standard

Re: [GENERAL] automating backup ?

2005-06-27 Thread Zlatko Matic
thank you Andreas! - Original Message - From: Andreas [EMAIL PROTECTED] To: pgsql-general@postgresql.org Cc: Zlatko Matic [EMAIL PROTECTED] Sent: Monday, June 27, 2005 12:43 PM Subject: Re: [GENERAL] automating backup ? Zlatko Matic schrieb: Thanks Fuhr. Anybody can tell me how to

Re: [GENERAL] Postfix/Maildrop and too many connections issues

2005-06-27 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2005-06-23 17:25:03 -0400: On Thu, 2005-06-23 at 03:39 +, Karl O. Pinc wrote: On 06/22/2005 08:23:43 AM, Sven Willenberger wrote: On Wed, 2005-06-22 at 01:30 +0200, Roman Neuhauser wrote: # [EMAIL PROTECTED] / 2005-06-21 15:00:12 -0400: We have a system set

Re: [GENERAL] Tablespaces across same raid...

2005-06-27 Thread Douglas McNaught
Himanshu Baweja [EMAIL PROTECTED] writes: i just have one raid controller with 6 disks attached... i see all of it as single drive with three partitions create by me... will creating tablespaces help me also is there a way i can say this table to this disk??? In a RAID, all data goes

Re: [GENERAL] number of records returned by cursors

2005-06-27 Thread Tom Lane
Zac [EMAIL PROTECTED] writes: does anyone know if there is a way (in plpgsql) to obtain the number of records returned by a cursor without fetching them all? No. The system itself does not know that until you've fully executed the query ... regards, tom lane

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Vivek Khera
On Jun 27, 2005, at 3:47 AM, Janning Vygen wrote: I had some problems with the calculation inside acos() sometimes being greater than 1, which should not occur. Please use a CASE WHEN sin(...) 1 THEN 1 ELSE sin(...) END if you have the same problem. We've seen this as well with the

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Vivek Khera
On Jun 26, 2005, at 7:40 PM, CSN wrote: If I have a table of items with latitude and longitude coordinates, is it possible to find all other items that are within, say, 50 miles of an item, using the geometric functions (http://www.postgresql.org/docs/8.0/interactive/functions-

[GENERAL] Status of pg_dump

2005-06-27 Thread K.Deepa
Dear All, Is there any way to check the santity of the backup taken using pg_dump? -- regards, Deepa K ---(end of broadcast)--- TIP 7: don't forget to increase your free space map settings

Re: [GENERAL] Infix Function?

2005-06-27 Thread Bruno Wolff III
On Sun, Jun 26, 2005 at 15:42:25 -0500, Peter Fein [EMAIL PROTECTED] wrote: Is there anyway to create an infix version of this? I'd really like be able to write (where a..d are some boolean conditions): Use : area= select true false true; ?column? -- f (1 row) area= select

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Bruno Wolff III
On Sun, Jun 26, 2005 at 16:40:03 -0700, CSN [EMAIL PROTECTED] wrote: If I have a table of items with latitude and longitude coordinates, is it possible to find all other items that are within, say, 50 miles of an item, using the geometric functions

Re: [GENERAL] Web application development on Win32, deployment on Linux

2005-06-27 Thread Alvaro Herrera
On Mon, Jun 27, 2005 at 01:59:42PM +0200, Magnus Hagander wrote: I currently maintain a website which is deployed on LAMP, but it is developed on Windows (WAMP?). I'm considering moving both to use PostgreSQL. I'm curious as to whether others are following a similar

Re: [GENERAL] Web application development on Win32, deployment on Linux

2005-06-27 Thread Magnus Hagander
I currently maintain a website which is deployed on LAMP, but it is developed on Windows (WAMP?). I'm considering moving both to use PostgreSQL. I'm curious as to whether others are following a similar development/deployment model and if so, what pitfalls/gotchas they have

Re: [GENERAL] Status of pg_dump

2005-06-27 Thread Vivek Khera
On Jun 27, 2005, at 8:29 AM, K.Deepa wrote: Dear All, Is there any way to check the santity of the backup taken using pg_dump? Send it to a psychotherapist? The only way to verify a backup is to restore from it and check it however you can (compare with original if it is unaltered, or

Re: [GENERAL] Web application development on Win32, deployment on

2005-06-27 Thread Scott Marlowe
On Mon, 2005-06-27 at 10:50, Alvaro Herrera wrote: Regarding replication, the Slony-I guys state that their project is not yet ported to Windows, but giving that there is a pthread library for Windows (which is about the only thing it lacks, apparently) then it should be possible to port it

[GENERAL] DANGER Windows version might hurt you

2005-06-27 Thread Andreas
I want to warn you all that you might hurt yourself by banging your head against the wall or damage your karma by using foul language if you find your postmaster rejecting to work after a minor change in the postgresql.conf. (I changed the listenig address to an IP instead of *.) Windows can't

Re: [GENERAL] DANGER Windows version might hurt you

2005-06-27 Thread Magnus Hagander
I want to warn you all that you might hurt yourself by banging your head against the wall or damage your karma by using foul language if you find your postmaster rejecting to work after a minor change in the postgresql.conf. (I changed the listenig address to an IP instead of *.) Windows

[GENERAL] problems with slow insert/delete queries/lot of disk write i/o in postgresql 7.2.4

2005-06-27 Thread Alexander Korobov
Hi, We are having strange problem on production system with very slow insert/delete commands and huge cpu and disk write activity spikes in postgresql 7.2.4. This behavior is very reproducible and happens in following sequence : 1. full db vacuum 2. several hundred of insert/delete commands are

Re: [GENERAL] DANGER Windows version might hurt you

2005-06-27 Thread Andreas
Magnus Hagander schrieb: Did you check the eventlog? It's supposed to write it there.. Well, you are right. =8-} There is FATAL: Syntaxfehler in Datei »[...]/PostgreSQL-8.0.3/postgresql.conf«, Zeile 322, bei »#« That's the error message I got on the console. I'm by far no Windows guru

[GENERAL] Populating huge tables each day

2005-06-27 Thread Ben-Nes Yonatan
Hi All, First I apologize for the length of this email im just afraid that my problem is quite complicated for explination also about my english which is not my native language sorry :) I'm currently building a site for a client which will need to update his database on a daily routine

[GENERAL] Vacuum analyze question on estimated rows

2005-06-27 Thread Sailer, Denis (YBUSA-CDR)
In the following output the vacuum knows there are 99,612 pages and 1,303,891 rows. However the last line of output during the analyze only thinks there are 213,627 rows. Is this so far off because the table is bloated? Version of PostgreSQL is PostgreSQL 7.4.3 on i686-pc-linux-gnu,

Re: [GENERAL] Populating huge tables each day

2005-06-27 Thread Dann Corbit
I see a lot of problems with this idea. You mention that the database is supposed to be available 24x7. While you are loading, the database table receiving data will not be available. Therefore, you will have to have one server online (with only the old data), while the other one is loading.

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Uwe C. Schroeder
Actually it does. I'm using a bounding box too. I have a stored procedure to get me what I need - here's the relevant part of it. Explanation: zc is the record holding the point of origin. I just added the maxdistance definition for this, because in my function its a parameter.

Re: [GENERAL] Populating huge tables each day

2005-06-27 Thread Jim C. Nasby
On Mon, Jun 27, 2005 at 12:43:57PM -0700, Dann Corbit wrote: I see a lot of problems with this idea. You mention that the database is supposed to be available 24x7. While you are loading, the database table receiving data will not be available. Therefore, you will have to have one server

Re: [GENERAL] Populating huge tables each day

2005-06-27 Thread Dann Corbit
-Original Message- From: Jim C. Nasby [mailto:[EMAIL PROTECTED] Sent: Monday, June 27, 2005 12:58 PM To: Dann Corbit Cc: Ben-Nes Yonatan; pgsql-general@postgresql.org Subject: Re: [GENERAL] Populating huge tables each day On Mon, Jun 27, 2005 at 12:43:57PM -0700, Dann Corbit

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread John Browne
I'm interested in doing a project for calculating distances similar to this. Anyone have suggestions on how/where this type of data can be obtained? Is it freely available anywhere? On 6/27/05, Uwe C. Schroeder [EMAIL PROTECTED] wrote: Actually it does. I'm using a bounding box too. I have

Re: [GENERAL] Finding points within 50 miles

2005-06-27 Thread Vivek Khera
On Jun 27, 2005, at 4:36 PM, John Browne wrote: I'm interested in doing a project for calculating distances similar to this. Anyone have suggestions on how/where this type of data can be obtained? Is it freely available anywhere? Google is your friend. There are places that sell very

[GENERAL] Indexes not used - what am I missing?

2005-06-27 Thread Relyea, Mike
Given my query: SELECT PrintSamples.MachineID , PrintSamples.PrintCopyID , tblColors.Color , tblBlockAC.AreaCoverage , tblFriendlyParameterNames.FriendlyParameterName AS Measurement , ParameterValues.ParameterValue AS Value FROM AnalysisModules

Re: [GENERAL] Indexes not used - what am I missing?

2005-06-27 Thread Relyea, Mike
I knew I would forget to include some obvious info. I'm running PG 8.0.x on WinXP and have vacuum full analyzed. -Original Message- From: Relyea, Mike Sent: Monday, June 27, 2005 5:10 PM To: 'pgsql-general@postgresql.org' Subject: Indexes not used - what am I missing? Given my query:

Re: [GENERAL] automating backup ?

2005-06-27 Thread Zlatko Matic
Hello. I created a Windows XP schedule for backup, following your instruction. Now I have a .bat file with this script: cd D:\Program Files\PostgreSQL\8.0\bin pg_dumpall D:\MYDATABASE_DUMPALL -U postgres pg_dumpall D:\MYDATABASE_SHEMA -U postgres -s pg_dumpall D:\MYDATABASE_GLOBALS -U postgres

Re: [GENERAL] Populating huge tables each day

2005-06-27 Thread Jim C. Nasby
On Mon, Jun 27, 2005 at 01:05:42PM -0700, Dann Corbit wrote: -Original Message- From: Jim C. Nasby [mailto:[EMAIL PROTECTED] Sent: Monday, June 27, 2005 12:58 PM To: Dann Corbit Cc: Ben-Nes Yonatan; pgsql-general@postgresql.org Subject: Re: [GENERAL] Populating huge tables

[GENERAL] performance for insert / update

2005-06-27 Thread Catalin Constantin
Hello, I have a pretty big database with about 200 000 rows. This is the main table. Also some other tables with FKs to this main table. I have to calculate some numbers for each entry at a certain amount of time and update the DB. I've noticed the update TAKES a very long time. For example i

Re: [GENERAL] Postmaster Out of Memory

2005-06-27 Thread Jeff Gold
Tom Lane wrote: TRUNCATE and CLUSTER both rebuild indexes, so they'd also trigger the leak. Sorry to bug you again, but I have two quick followup questions: (1) is the leak you discovered fixed on the 8.0 branch? and (2) would closing the database connection once per day be a reasonable way

[GENERAL] Generate a list of (days/hours) between two dates

2005-06-27 Thread ben . hallert
Hi guys, I've scoured the date/time functions in the docs as well as google-grouped as many different combinations as I could think of to figure this out without asking, but I'm having no luck. I'd like to make a query that would return a list of every trunc'd TIMESTAMPs between two dates. For