[GENERAL] tsearch2 questions

2007-07-04 Thread Joshua N Pritikin
1. What is the advantage of the tsearch2() trigger? Why can't I write my own trigger which does approximately: UPDATE manuscript set manuscript_vector = setweight(to_tsvector(manuscript_genre), 'A') || setweight(to_tsvector(manuscript_title), 'B') ||

Re: [GENERAL] How do I aggregate data from multiple rows into a delimited list?

2007-07-04 Thread D. Dante Lorenso
Berend Tober wrote: D. Dante Lorenso wrote: I want to select several rows of data and have them returned in a single record with the rows joined by a delimiter. Review the User Comments at http://www.postgresql.org/docs/8.0/interactive/sql-createaggregate.html; for some ideas. I found a

Re: [GENERAL] tsearch2 questions

2007-07-04 Thread Oleg Bartunov
On Wed, 4 Jul 2007, Joshua N Pritikin wrote: 1. What is the advantage of the tsearch2() trigger? Why can't I write my own trigger which does approximately: no advantage, it's just an example. UPDATE manuscript set manuscript_vector = setweight(to_tsvector(manuscript_genre), 'A') ||

Re: [GENERAL] Design Tool

2007-07-04 Thread Hannes Dorbath
On 03.07.2007 21:43, Gabriele wrote: Free or not so costly license. If i use postgresql is also to save money, as you might expect. A one hundred dollars software might be my solution, a one thousand dollars is probably not. Casestudio.. or Toad Data Modeler, as it is named these days, is

Re: [GENERAL] Reasonable way to backup cluster Windows

2007-07-04 Thread Hannes Dorbath
On 03.07.2007 17:18, Andrus wrote: Which is reasonable way to backup cluster in Windows in compressed format ? Is the windows pg_dump different from the *nix one? If not, what is the problem with -Fc? -- Regards, Hannes Dorbath ---(end of

Re: [GENERAL] Stored Procedure: Copy table from; path = text variable

2007-07-04 Thread Dave Page
Richard Huxton wrote: Dave Page wrote: Richard Huxton wrote: Charles Pare wrote: Wow, it works great Thank's for the quick answer 12 minutes? I've seen bug-patches turned around quicker than that by Tom ;-) Yeah, that's really quite disappointing Richard - you need to pull your socks up

Re: [GENERAL] tsearch2 questions

2007-07-04 Thread Joshua N Pritikin
On Wed, Jul 04, 2007 at 10:59:46AM +0400, Oleg Bartunov wrote: On Wed, 4 Jul 2007, Joshua N Pritikin wrote: 1. What is the advantage of the tsearch2() trigger? Why can't I write my own trigger which does approximately: no advantage, it's just an example. Please mention that in the

Re: [GENERAL] tsearch2 questions

2007-07-04 Thread hubert depesz lubaczewski
On 7/4/07, Joshua N Pritikin [EMAIL PROTECTED] wrote: Please mention that in the documentation: dont you think this is perfeclty clear? If you want to do something specific with columns, you may write your very own trigger function using plpgsql or other procedural languages (but not SQL,

Re: [GENERAL] Date for a week day of a month

2007-07-04 Thread hubert depesz lubaczewski
On 7/3/07, Emi Lu [EMAIL PROTECTED] wrote: Can I know how to get the date of each month's last Thursday please? Query: select getDateBaseOnWeekday('2007-04-01', 'Last Thursday'); Result: 2007-04-26 you can easily do it without functions. for example, this select: SELECT cast(d.date + i *

Re: [GENERAL] tsearch2 questions

2007-07-04 Thread Joshua N Pritikin
On Wed, Jul 04, 2007 at 10:40:11AM +0200, hubert depesz lubaczewski wrote: On 7/4/07, Joshua N Pritikin [EMAIL PROTECTED] wrote: Please mention that in the documentation: dont you think this is perfeclty clear? If you want to do something specific with columns, you may write your very own

Re: [GENERAL] tsearch2 questions

2007-07-04 Thread hubert depesz lubaczewski
On 7/4/07, Joshua N Pritikin [EMAIL PROTECTED] wrote: From where are you quoting? I was quoting from: http://www.sai.msu.su/~megera/postgres/gist/tsearch/V2/docs/tsearch2-ref.html i was quoting file http://www.sai.msu.su/~megera/postgres/gist/tsearch/V2/docs/tsearch-V2-intro.html or

Re: [GENERAL] tsearch2 questions

2007-07-04 Thread Joshua N Pritikin
On Wed, Jul 04, 2007 at 11:08:21AM +0200, hubert depesz lubaczewski wrote: On 7/4/07, Joshua N Pritikin [EMAIL PROTECTED] wrote: From where are you quoting? I was quoting from: http://www.sai.msu.su/~megera/postgres/gist/tsearch/V2/docs/tsearch2-ref.html i was quoting file

[GENERAL] tsearch2 in multilingual database?

2007-07-04 Thread Joshua N Pritikin
Sometime in the future, I anticipate storing other languages in addition to English in my database to be indexed with tsearch2. set_curcfg() seems to be per-session. Will I need to call set_curcfg() every time I switch languages? -- Make April 15 just another day, visit http://fairtax.org

Re: [GENERAL] how to covert a column?

2007-07-04 Thread Albe Laurenz
Dimitrius Weddington wrote: I have a dataset (90GBs worth) that contains 3 columns of unix timestamps in seconds. Ideally, I want to use copy to load the data into the DB (the disk i/o of trying to process this volume of data vi perl takes a couple of days). I was hoping to convert the

Re: [GENERAL] Mugs 'n stuff

2007-07-04 Thread Geoffrey
A. Kretschmer wrote: am Tue, dem 03.07.2007, um 23:37:57 +0100 mailte Raymond O'Donnell folgendes: Hi all, Is it still possible to get PostgreSQL merchandise? A friend of mine is looking for some, but I can't seem to find where its available. Can you or your fried visit the pgday.it at

Re: [GENERAL] Date for a week day of a month

2007-07-04 Thread Emi Lu
generate_series that's a good one! Thank you! On 7/3/07, Emi Lu [EMAIL PROTECTED] wrote: Can I know how to get the date of each month's last Thursday please? Query: select getDateBaseOnWeekday('2007-04-01', 'Last Thursday'); Result: 2007-04-26 you can easily do it without functions. for

Re: [GENERAL] Mugs 'n stuff

2007-07-04 Thread Raymond O'Donnell
On 04/07/2007 14:20, Geoffrey wrote: A. Kretschmer wrote: We, the german postgresql user group, have some stuff like blue plush elephants, shirts and coffee-cups, see also http://ads.wars-nicht.de/blog/ (scroll a little bit down), this will be available in Prato. I've always had luck finding

Re: [GENERAL] Design Tool

2007-07-04 Thread Hannes Dorbath
On 04.07.2007 10:44, Gabriele wrote: Anyway it doesn't support SQLite. Casestudio is a script based framework, there is lot of user contributed stuff. I remember having seen SQLite support somewhere, if not it's not so hard to add support yourself. -- Regards, Hannes Dorbath

Re: [GENERAL] Reasonable way to backup cluster Windows

2007-07-04 Thread Hannes Dorbath
On 04.07.2007 10:42, Andrus wrote: I use pg_dumpall -g but in this case I have two backup files: one regular backup and second contains sql scripts for user creation. How to force pg_dump to backup users also ? There is no way around that. pg_dumpall -g pg_dump -Fc for each DB. -- Regards,

Re: [GENERAL] blobs

2007-07-04 Thread Michael Glaesemann
On Jul 4, 2007, at 11:34 , Cesar Alvarez wrote: is there a way to store pictures or executables in postgres?? From the PostgreSQL FAQ 4.10) What is the difference between the various character types? http://www.postgresql.org/docs/faqs.FAQ.html#item4.10 From the PostgreSQL Documentation

[GENERAL] blobs

2007-07-04 Thread Cesar Alvarez
hello every one is there a way to store pictures or executables in postgres?? Cesar Alvarez. begin:vcard fn:Cesar Alvarez n:;Cesar Alvarez title:Web Development Asesor and Software Enginner version:2.1 end:vcard ---(end of broadcast)--- TIP 6:

Re: [GENERAL] blobs

2007-07-04 Thread Raymond O'Donnell
On 04/07/2007 17:34, Cesar Alvarez wrote: is there a way to store pictures or executables in postgres?? http://www.postgresql.org/docs/8.2/static/datatype-binary.html --- Raymond O'Donnell, Director of Music, Galway Cathedral,

Re: [GENERAL] What O/S or hardware feature would be useful for databases?

2007-07-04 Thread Andrej Ricnik-Bay
On 7/4/07, Ron Johnson [EMAIL PROTECTED] wrote: Enterprise-level tapes can sit in storage for 7-15 years and then still be readable. Can a disk drive sit un-used for 7 years? Would the motor freeze up? Will we still be able to connect SATA drives in 7 years? Same with a tape-drive, no?

Re: [GENERAL] [general] growing disk usage problem: alternative solution?

2007-07-04 Thread wu_zhong_min
Thanks all for the replies. Mr. Wu Zong-min ---(end of broadcast)--- TIP 6: explain analyze is your friend

[GENERAL] Problem with autovacuum and pg_autovacuum

2007-07-04 Thread Andreas 'ads' Scherbaum
Hello, we got a small problem with auto_vacuum: since we have some big tables which have heavy read/write access, we tried to exclude this tables from autovacuum: database1=# select vacrelid,enabled,(select relname from pg_class where oid=vacrelid) as relname from pg_autovacuum; vacrelid |

[GENERAL] perpetual dump/restore problem

2007-07-04 Thread wu_zhong_min
Dear List, As many of you know every time one wants to upgrade to a major server version, as I want to do now, there is a need for pg_dumpall and restore. This is a huge undertaking and requires lots of testing and planning. I do hope that in the future this requirement will be dropped. I

Re: [GENERAL] Problem with autovacuum and pg_autovacuum

2007-07-04 Thread Alvaro Herrera
Andreas 'ads' Scherbaum wrote: Hello, we got a small problem with auto_vacuum: since we have some big tables which have heavy read/write access, we tried to exclude this tables from autovacuum: database1=# select vacrelid,enabled,(select relname from pg_class where oid=vacrelid) as

Re: [GENERAL] Problem with autovacuum and pg_autovacuum

2007-07-04 Thread Andreas 'ads' Scherbaum
Hello, On Wed, 4 Jul 2007 18:04:35 -0400 Alvaro Herrera wrote: Most likely it is worried about XID wraparound, and those are precisely the tables that need urgent vacuumed because they haven't been vacuumed in a long time. No, autovacuum is doing this with every run. Beside this, the

Re: [GENERAL] Problem with autovacuum and pg_autovacuum

2007-07-04 Thread Alvaro Herrera
Andreas 'ads' Scherbaum wrote: Hello, On Wed, 4 Jul 2007 18:04:35 -0400 Alvaro Herrera wrote: Most likely it is worried about XID wraparound, and those are precisely the tables that need urgent vacuumed because they haven't been vacuumed in a long time. No, autovacuum is doing

Re: [GENERAL] Problem with autovacuum and pg_autovacuum

2007-07-04 Thread Andreas 'ads' Scherbaum
Hello, On Wed, 4 Jul 2007 18:40:15 -0400 Alvaro Herrera wrote: Andreas 'ads' Scherbaum wrote: On Wed, 4 Jul 2007 18:04:35 -0400 Alvaro Herrera wrote: Most likely it is worried about XID wraparound, and those are precisely the tables that need urgent vacuumed because they haven't

Re: [GENERAL] Problem with autovacuum and pg_autovacuum

2007-07-04 Thread Alvaro Herrera
Andreas 'ads' Scherbaum wrote: Hello, On Wed, 4 Jul 2007 18:40:15 -0400 Alvaro Herrera wrote: Andreas 'ads' Scherbaum wrote: On Wed, 4 Jul 2007 18:04:35 -0400 Alvaro Herrera wrote: Most likely it is worried about XID wraparound, and those are precisely the tables that

Re: [GENERAL] What O/S or hardware feature would be useful for databases?

2007-07-04 Thread Ron Johnson
On 07/04/07 16:00, Andrej Ricnik-Bay wrote: On 7/4/07, Ron Johnson [EMAIL PROTECTED] wrote: Enterprise-level tapes can sit in storage for 7-15 years and then still be readable. Can a disk drive sit un-used for 7 years? Would the motor freeze up? Will we still be able to connect SATA drives

Re: [GENERAL] What O/S or hardware feature would be useful for databases?

2007-07-04 Thread Tom Lane
Andrej Ricnik-Bay [EMAIL PROTECTED] writes: On 7/4/07, Ron Johnson [EMAIL PROTECTED] wrote: Enterprise-level tapes can sit in storage for 7-15 years and then still be readable. Can a disk drive sit un-used for 7 years? Would the motor freeze up? Will we still be able to connect SATA drives