Re: [GENERAL] Vacuum non-clustered tables only

2007-05-16 Thread Richard Huxton
Glen Parker wrote: I think I know the answer to this, but... Is there a semi-easy way vacuum all tables in a database *except* those that are clustered? (VACUUM [full]; CLUSTER;) is a huge waste of time and resources when you have clustered tables. If there isn't a way to do this, can we co

Re: [GENERAL] Fixing broken permissions for deleted user

2007-05-16 Thread Tom Lane
"Justin Pasher" <[EMAIL PROTECTED]> writes: > OK. After playing around with this extensively I FINALLY got the permissions > remove (from anything I can see). > ... > The table owner is also a different user from user id 101. However, it still > gives me the same complaint. > pg_dump: WARNING: own

Re: [GENERAL] cube operations

2007-05-16 Thread Oleg Bartunov
hacking contrib/intarray could help you. You need to add function which return the number of overlapped elements. Oleg On Wed, 16 May 2007, John D. Burger wrote: ABHANG RANE wrote: I have a array column which has 12 real values in it. Basically these values represent co-ordinates in 12 dimen

Re: [GENERAL] Windows Vista Support

2007-05-16 Thread Paul Lambert
[EMAIL PROTECTED] wrote: Can you confirm that you don't provide support for Windows Vista for any release of Postgres. I'm dumbfounded an it appears that you don't support Vista. If so, are you planning any releases. I have a major project and was hoping to use Postgres. Michael Alexander

[GENERAL] Windows Vista Support

2007-05-16 Thread michael . alexander
Can you confirm that you don't provide support for Windows Vista for any release of Postgres. I'm dumbfounded an it appears that you don't support Vista. If so, are you planning any releases. I have a major project and was hoping to use Postgres.     Michael Alexander Impower

Re: [GENERAL] Fixing broken permissions for deleted user

2007-05-16 Thread Justin Pasher
> -Original Message- > From: Richard Huxton [mailto:[EMAIL PROTECTED] > Sent: Wednesday, May 16, 2007 4:56 AM > To: Justin Pasher > Cc: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Fixing broken permissions for deleted user > > Justin Pasher wrote: > > I have a PostgreSQL 7.4.14 d

Re: [GENERAL] Vacuum non-clustered tables only

2007-05-16 Thread Jim C. Nasby
On Wed, May 16, 2007 at 03:40:27PM -0700, Glen Parker wrote: > I think I know the answer to this, but... > > Is there a semi-easy way vacuum all tables in a database *except* those > that are clustered? You could query for tables that aren't clustered and use that to build a list of VACUUM comm

Re: [GENERAL] cube operations

2007-05-16 Thread John D. Burger
ABHANG RANE wrote: I have a array column which has 12 real values in it. Basically these values represent co-ordinates in 12 dimensions for a substance. My main need is to find substances similar to a particular compound. Now I can do by calculating differences with each array in the whol

Re: [GENERAL] HowTo SSL probaply with ODBC ?

2007-05-16 Thread John DeSoi
On May 16, 2007, at 10:23 AM, Andreas wrote: is there a documentation on how to secure a connection withe SSL? That is an option of the ODBC driver, isn't it? http://www.postgresql.org/docs/8.2/interactive/ssl-tcp.html I don't know about ODBC. The motivation is that I need to rent a remo

Re: [GENERAL] Vacuum non-clustered tables only

2007-05-16 Thread Joshua D. Drake
Glen Parker wrote: I think I know the answer to this, but... Is there a semi-easy way vacuum all tables in a database *except* those that are clustered? Not that I know of. J (VACUUM [full]; CLUSTER;) is a huge waste of time and resources when you have clustered tables. If there isn't

[GENERAL] Vacuum non-clustered tables only

2007-05-16 Thread Glen Parker
I think I know the answer to this, but... Is there a semi-easy way vacuum all tables in a database *except* those that are clustered? (VACUUM [full]; CLUSTER;) is a huge waste of time and resources when you have clustered tables. If there isn't a way to do this, can we consider it a feature

Re: [GENERAL] Performance issues of one vs. two split tables.

2007-05-16 Thread Brian Wipf
On 16-May-07, at 4:05 PM, PFC wrote: This makes queries hard to optimize. Consider the table (user_id, item_id) meaning user selected this item as favourite. If you want to know which users did select both items 1 and 2, you have to do a self-join, something like : SELECT... FROM favourite

Re: [GENERAL] Constructing a SELECT statement in pl/pgsql

2007-05-16 Thread Richard Huxton
Robert Fitzpatrick wrote: I guess my question is how to replace the following... FOR searchresults IN SELECT * FROM my_view WHERE LOOP With something like this... FOR searchresults IN SELECT DISTINCT clientname FROM my_view WHERE LOOP Build the query as text and use EXECUTE (see manuals fo

[GENERAL] Constructing a SELECT statement in pl/pgsql

2007-05-16 Thread Robert Fitzpatrick
I have a function that returns a set of records based on one of my views. The function takes two arguments of user_id and saved search name, looks up the search values from a table previously saved and performs a SELECT query on my view to return my set of records found. However, I don't want to SE

Re: [GENERAL] Performance issues of one vs. two split tables.

2007-05-16 Thread PFC
We use bitfields on our large user table. It is becoming unworkable to scan for matches, since overall most people have very few selections made. We are moving it to a model like your favorite_colors table which just links the option and the user. We find that doing joins on large tables

Re: [GENERAL] cube operations

2007-05-16 Thread Filip Rembiałkowski
2007/5/16, ABHANG RANE <[EMAIL PROTECTED]>: Hi, I have a array column which has 12 real values in it. Basically these values represent co-ordinates in 12 dimensions for a substance. My main need is to find substances similar to a particular compound. Now I can do by calculating differences with e

Re: [GENERAL] Postgres Printed Manuals

2007-05-16 Thread Rich Shepard
On Wed, 16 May 2007, Vivek Khera wrote: Seems like an ideal use of those print-on-demand services like lulu.com among others. The project could post an official PDF of the docs, and take a cut every time someone ordered a printed copy. The question is who would take the time to make a professi

Re: [GENERAL] Performance issues of one vs. two split tables.

2007-05-16 Thread Vivek Khera
On May 15, 2007, at 10:35 AM, Bill Moseley wrote: For some value of "large", is there a time when one might consider using a single column in the user or user_prefs table to represent their color choices instead of a link table? We use bitfields on our large user table. It is becoming unwork

Re: [GENERAL] Performance issues of one vs. two split tables.

2007-05-16 Thread Vivek Khera
On May 14, 2007, at 4:37 PM, Bill Moseley wrote: Say that there's also about 10 columns of settings or preferences for each user. Are there any cases or reasons to have a separate "user_preferences" table vs. just placing all the columns together in one table? when you have, say 65 million u

Re: [GENERAL] Postgres Printed Manuals

2007-05-16 Thread Joshua D. Drake
Vivek Khera wrote: On May 13, 2007, at 10:43 PM, Tom Lane wrote: It's hard to make any money that way :-(. Rich Morin used to run a business called "Prime Time Freeware" that published hardcopy versions of our manuals along with much other open-source documentation. He gave up on it some year

Re: [GENERAL] stats collector spins my disk up every 500ms (8.2.3)

2007-05-16 Thread Alvaro Herrera
Tom Lane wrote: > Alvaro Herrera <[EMAIL PROTECTED]> writes: > > Daniel Barlow wrote: > > >> Questions: > >> 1) this is on a system with I believe to be quiescent - there is only > >> one client open which is not doing anything. Before I get more involved > >> with this, can someone just confirm

Re: [GENERAL] Postgres Printed Manuals

2007-05-16 Thread Vivek Khera
On May 13, 2007, at 10:43 PM, Tom Lane wrote: It's hard to make any money that way :-(. Rich Morin used to run a business called "Prime Time Freeware" that published hardcopy versions of our manuals along with much other open-source documentation. He gave up on it some years ago, though, and I

[GENERAL] cube operations

2007-05-16 Thread ABHANG RANE
Hi, I have a array column which has 12 real values in it. Basically these values represent co-ordinates in 12 dimensions for a substance. My main need is to find substances similar to a particular compound. Now I can do by calculating differences with each array in the whole table. But the tab

Re: [GENERAL] a few questions on backup

2007-05-16 Thread Marco Colombo
Tom Lane wrote: > Marco Colombo <[EMAIL PROTECTED]> writes: >> Good to know, thanks. I think I'll experiment a bit with >> archive_command. My point was that since I know (or better assume) that >> old segments are going to stay in my pg_xlog for *days* before getting >> recycled, > > On what do y

Re: [GENERAL] to_number behavior change between 8.1 and 8.2

2007-05-16 Thread Richard Greenwood
On 5/16/07, Joshua D. Drake <[EMAIL PROTECTED]> wrote: Richard Greenwood wrote: > I am getting an error from to_number() in PostgreSQL 8.2 that does not > occur in 8.1: > invalid input syntax for type numeric: " " > I assume that it is rejecting spaces, so I tried trimming with: > to_number(t

Re: [GENERAL] a few questions on backup

2007-05-16 Thread Tom Lane
Marco Colombo <[EMAIL PROTECTED]> writes: > Good to know, thanks. I think I'll experiment a bit with > archive_command. My point was that since I know (or better assume) that > old segments are going to stay in my pg_xlog for *days* before getting > recycled, On what do you base that assumption?

Re: [GENERAL] stats collector spins my disk up every 500ms (8.2.3)

2007-05-16 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > Daniel Barlow wrote: >> Questions: >> 1) this is on a system with I believe to be quiescent - there is only >> one client open which is not doing anything. Before I get more involved >> with this, can someone just confirm that pgstat will continue to u

Re: [GENERAL] stats collector spins my disk up every 500ms (8.2.3)

2007-05-16 Thread Ron Mayer
Alvaro Herrera wrote: > Daniel Barlow wrote: >> 1 battery life from my laptop, I noticed that one source of periodic disk >> writes was the postgres stats collector process, which appears to >> write to pgstat.tmp every 500ms) > > Hmm, I don't think we have an optimization to avoid writing it wh

Re: [GENERAL] to_number behavior change between 8.1 and 8.2

2007-05-16 Thread Richard Huxton
Richard Greenwood wrote: I am getting an error from to_number() in PostgreSQL 8.2 that does not occur in 8.1: invalid input syntax for type numeric: " " I assume that it is rejecting spaces, so I tried trimming with: to_number(trim (both ' ' from streetnum),'9') but still get the same

Re: [GENERAL] to_number behavior change between 8.1 and 8.2

2007-05-16 Thread Joshua D. Drake
Richard Greenwood wrote: I am getting an error from to_number() in PostgreSQL 8.2 that does not occur in 8.1: invalid input syntax for type numeric: " " I assume that it is rejecting spaces, so I tried trimming with: to_number(trim (both ' ' from streetnum),'9') but still get the same

Re: [GENERAL] dns less connection

2007-05-16 Thread marcelo Cortez
Andreas ,Magnus I do where you say me but... ' ''IM002: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified''') i'm follow your instrutions and replace parts of connectString but don't work . Later a try with debugging options. best regards MDC --- And

[GENERAL] to_number behavior change between 8.1 and 8.2

2007-05-16 Thread Richard Greenwood
I am getting an error from to_number() in PostgreSQL 8.2 that does not occur in 8.1: invalid input syntax for type numeric: " " I assume that it is rejecting spaces, so I tried trimming with: to_number(trim (both ' ' from streetnum),'9') but still get the same error. Any suggestions?

Re: [GENERAL] basic postgres questions...

2007-05-16 Thread Ray Stell
On Wed, May 16, 2007 at 08:21:59AM -0700, bruce wrote: > hey.. . > > can someone point me to the cmds that i'd use in order to see what databases > are created in my postgres app. i need to see what's here, and then i need template1=# select datname, oid from pg_database; datname | oid --

[GENERAL] basic postgres questions...

2007-05-16 Thread bruce
hey.. . can someone point me to the cmds that i'd use in order to see what databases are created in my postgres app. i need to see what's here, and then i need to know the cmd to then delete a given database, and the underlying tables. in searching google, i'm seeing different cmds... also, is t

Re: [GENERAL] dns less connection

2007-05-16 Thread Andreas
There is actually an ODBC list vor PG availlable ;) The drivers name is postgresql unicode orpostgresql ansidepending on your needs. Driver={PostgreSQL UNICODE};DATABASE=X1;SERVER=X2;PORT=X3;UID=X4;PWD=X5;X6; This is the connection string but you have to replace X1 with the name of

Re: [GENERAL] Plpgsql function and variable substitute

2007-05-16 Thread Alban Hertroys
Jiří Němec wrote: > SET expiretime = expiretime + interval 'lifetime days' > SET expiretime = expiretime + interval || lifetime || 'days' SET expiretime = expiretime + lifetime * interval '1 day' -- Alban Hertroys [EMAIL PROTECTED] magproductions b.v. T: ++31(0)534346874 F: ++31(0)534346876 M:

Re: [GENERAL] dns less connection

2007-05-16 Thread Magnus Hagander
No, you need pgsqlodbc installed. You just don't need a DSN configured, but the driver has to be installed. //Magnus On Wed, May 16, 2007 at 10:19:29AM -0300, marcelo Cortez wrote: > Hi folks > > Magnus thanks for respond, but i can't success full > with this. > Hi think it's string connection m

[GENERAL] HowTo SSL probaply with ODBC ?

2007-05-16 Thread Andreas
Hi, is there a documentation on how to secure a connection withe SSL? That is an option of the ODBC driver, isn't it? The motivation is that I need to rent a remote server for PG. Their admin proposes to open port 5432 on the outside of their firewall but he has no idea how to secure the access

Re: [GENERAL] Plpgsql function and variable substitute

2007-05-16 Thread A. Kretschmer
am Wed, dem 16.05.2007, um 15:11:17 +0200 mailte Ji?í N?mec folgendes: > Hello, > > I have searched the Internet for an answer but nothing works for me. > > There is a plpgsql function which is used in a trigger. I need to > substitute a value "7" for "lifetime" (integer) SELECTed in a previous

Re: [GENERAL] Postgres Printed Manuals

2007-05-16 Thread Ian Harding
On 5/14/07, Alvaro Herrera <[EMAIL PROTECTED]> wrote: Rich Shepard wrote: > On Mon, 14 May 2007, Bruce Momjian wrote: > > >How much would it be to email the PDF manual to someone like Kinkos and > >get it printed? Effectively, that might be the cheepest solution because > >it is print-on-demand.

[GENERAL] Plpgsql function and variable substitute

2007-05-16 Thread Jiří Němec
Hello, I have searched the Internet for an answer but nothing works for me. There is a plpgsql function which is used in a trigger. I need to substitute a value "7" for "lifetime" (integer) SELECTed in a previous query. DECLARE lifetime integer; BEGIN SELECT foo INTO lifetime FROM tblnam

Re: [GENERAL] dns less connection

2007-05-16 Thread marcelo Cortez
Hi folks Magnus thanks for respond, but i can't success full with this. Hi think it's string connection mater, but can't connect, you try any time without pgsqlodbc installed?. I'm not using (vb) :D but using COM way. Every time odcb reclaim for MS "dont know default driver" or something like th

Re: [GENERAL] OIDs - file objects, are damaged by PostgreSQL.

2007-05-16 Thread Richard Huxton
Purusothaman A wrote: Hi all, I am using Postgresql 8.2. 8.2.which? I am using client side api to upload/download files to/from postgresql using calls lo_export()/lo_import(); If I download a file from postgresql, few weeks later, files object's contents got damaged. I don't know why. Do

Re: [GENERAL] Fixing broken permissions for deleted user

2007-05-16 Thread Richard Huxton
Justin Pasher wrote: I have a PostgreSQL 7.4.14 database that is being backed up nightly using pg_dump. Some time back, we deleted a user from the server that was no longer employed. This in turn caused some problems with ownership of some of the tables (since the user didn't exist, the databas