Re: [GENERAL] password cookie

2006-10-26 Thread Willy-Bas Loos
> My suggestion is "don't do that".> I tried to do it once, years ago, and regretted it deeply.Do you mean "don´t try to fake postgres´ authorisation" (which i don´t want to),or "don´t set up your webservice so that users will recieve data according to their own rights in the database, where each f

Re: [GENERAL] Reducing pg_dump & pg_restore times

2006-10-26 Thread Stefan Kaltenbrunner
Ron Johnson wrote: > On 10/26/06 01:20, Chris wrote: >>> Coder At Heart wrote: Hi! Restore & backup take time in the tune of 6 hrs on a Linux, 4 proc, 32 G RAM machine for a 60GB database. >>> Please always cc the mailing list. >>> >>> I've never played with databases that lar

Re: [GENERAL] pg_dumpall failing from possible corrupted shared memory

2006-10-26 Thread Tom Lane
Richard Broersma Jr <[EMAIL PROTECTED]> writes: > mydb=# select pg_get_indexdef(indexrelid) from pg_index where indrelid = > '16737'; > server closed the connection unexpectedly So what do you get from 'select * from pg_index where indrelid = 16737' ? If that crashes, which individual columns can

Re: [GENERAL] pg_dumpall failing from possible corrupted shared memory

2006-10-26 Thread Richard Broersma Jr
> > > but before you do that, I'd urge > > > you to try to get as much info as you can about the nature of the > > > catalog corruption. If there's a bug here, as opposed to random > > > cosmic-ray damage, we can't fix it without more info. > > I eliminated the non-offending index with this query

Re: [GENERAL] Reducing pg_dump & pg_restore times

2006-10-26 Thread Robert Treat
On Thursday 26 October 2006 02:20, Chris wrote: > Coder At Heart wrote: > > Hi! > > > > Restore & backup take time in the tune of 6 hrs on a Linux, 4 proc, 32 G > > RAM machine for a 60GB database. > > Please always cc the mailing list. > > I've never played with databases that large so I don't kno

Re: [GENERAL] [SQL] Can we convert from Postgres to Oracle !!???

2006-10-26 Thread Jim C. Nasby
On Sun, Oct 22, 2006 at 12:03:38AM +0300, Devrim GUNDUZ wrote: > On Tue, 2006-10-17 at 14:21 +0530, Sandeep Kumar Jakkaraju wrote: > > Can we convert from Postgres to Oracle !!??? You can also run our software and get Oracle syntax for 1/25th the cost. -- Jim Nasby

Re: [GENERAL] regarding PostgreSQL

2006-10-26 Thread Jim C. Nasby
On Mon, Oct 23, 2006 at 11:19:13PM +0530, sumit kumar wrote: > Hello , > does anybody help me out telling how the PostGRESQL estimates > cardinality of LIKE operator. Try asking on pgsql-hackers... (sorry, I don't know the answer myself). -- Jim Nasby

Re: [GENERAL] pg_dumpall failing from possible corrupted shared memory

2006-10-26 Thread Richard Broersma Jr
> >Worst-case, you can probably fix things by dropping and > > recreating the constraint or index ...log_min_messages = info but before > > you do that, I'd > urge > > you to try to get as much info as you can about the nature of the > > catalog corruption. If there's a bug here, as opposed to r

Re: [GENERAL] database not enforcing unqiue constriant

2006-10-26 Thread Merlin Moncure
On 10/27/06, Joshua D. Drake <[EMAIL PROTECTED]> wrote: Merlin Moncure wrote: > My previous employer contacted me today. Apparently they are having > an increasing frequency of occurances where they disocover violations > of the primary key constraint not being caught by the database. This > sy

Re: [GENERAL] database not enforcing unqiue constriant

2006-10-26 Thread Joshua D. Drake
Merlin Moncure wrote: > My previous employer contacted me today. Apparently they are having > an increasing frequency of occurances where they disocover violations > of the primary key constraint not being caught by the database. This > system is an ISAM emulation system, and it relies heavily on

Re: [GENERAL] pg_dumpall failing from possible corrupted shared memory

2006-10-26 Thread Richard Broersma Jr
> What this looks like is that there's a mangled expression string in > the catalog entry for either a check constraint or an expression index. > The backend is dying while trying to decompile the expression for > pg_dump. you were write, I appears that my problem is with one of four functional d

[GENERAL] database not enforcing unqiue constriant

2006-10-26 Thread Merlin Moncure
My previous employer contacted me today. Apparently they are having an increasing frequency of occurances where they disocover violations of the primary key constraint not being caught by the database. This system is an ISAM emulation system, and it relies heavily on the database throwing unique

Re: [GENERAL] Possible problem with PQescapeStringConn and

2006-10-26 Thread Jeff Davis
On Thu, 2006-10-26 at 19:46 -0400, Tom Lane wrote: > Jeff Davis <[EMAIL PROTECTED]> writes: > > You can set standard_conforming_strings in postgresql.conf at any time > > and reload the config, changing the value for all active connections. > > That means that if a client opens a connection, and yo

Re: [GENERAL] pg_dumpall failing from possible corrupted shared memory

2006-10-26 Thread Tom Lane
Richard Broersma Jr <[EMAIL PROTECTED]> writes: > You'll have to forgive me. I've never used gdb before, I am not sure I > am executing gdb with the correct syntax. However, I was able to > produce a core file. Here is the syntax that I used that produced the > most output - althought it doesn't

Re: [GENERAL] pg_dumpall failing from possible corrupted shared memory

2006-10-26 Thread Richard Broersma Jr
> No, you just need to make sure the postmaster is started under > "ulimit -c unlimited", not "ulimit -c 0" which is the default > under many Linuxen. Adding this to the start script is the > easiest way usually. > > If you can't get anything but numbers from gdb's stack trace > then you have a "

Re: [GENERAL] Possible problem with PQescapeStringConn and standard_conforming_strings

2006-10-26 Thread Tom Lane
Jeff Davis <[EMAIL PROTECTED]> writes: > You can set standard_conforming_strings in postgresql.conf at any time > and reload the config, changing the value for all active connections. > That means that if a client opens a connection, and you SIGHUP postgres, > and then the client issues a PQescapeS

Re: [GENERAL] Possible problem with PQescapeStringConn and

2006-10-26 Thread Jeff Davis
On Thu, 2006-10-26 at 16:19 -0700, Jeff Davis wrote: > You can set standard_conforming_strings in postgresql.conf at any time > and reload the config, changing the value for all active connections. I should have mentioned, my email only applies to the upcoming 8.2 release. Regards, Jeff D

[GENERAL] Possible problem with PQescapeStringConn and standard_conforming_strings

2006-10-26 Thread Jeff Davis
You can set standard_conforming_strings in postgresql.conf at any time and reload the config, changing the value for all active connections. That means that if a client opens a connection, and you SIGHUP postgres, and then the client issues a PQescapeStringConn, the client will get an incorrectly

Re: [GENERAL] Compiling ELF 64-bit on Solaris

2006-10-26 Thread Andrew Sullivan
On Thu, Oct 26, 2006 at 12:40:41PM -0700, [EMAIL PROTECTED] wrote: > How can I get the "make" to generate ELF 64-bit executables on Solaris 10? > > We're on Fujitsu hardware; uname -a displays this: > SunOS 5.10 Generic_118822-26 sun4us sparc FJSV,GPUZC-M Well, to start with, are you using

Re: [GENERAL] Effect of large text field data on queries

2006-10-26 Thread Tom Lane
Glen Parker <[EMAIL PROTECTED]> writes: > How can I determine the default storage type for a given TOASTable > data type (text in this case)? Look in pg_type ... but they mostly default to "extended". regards, tom lane ---(end of broadcast)

Re: [GENERAL] schema 8.1.5

2006-10-26 Thread Tom Lane
km <[EMAIL PROTECTED]> writes: > how do i set a user account to default to a predefined schema ? If you make the choice user name = schema name, this happens for free. See http://www.postgresql.org/docs/8.1/static/ddl-schemas.html The bit about common usage patterns might help in particular. >

Re: [GENERAL] Effect of large text field data on queries

2006-10-26 Thread Glen Parker
Tom Lane wrote: Glen Parker <[EMAIL PROTECTED]> writes: How much of a TOAST'd field is actually stored in the main heap table? Is there a way to configure that amount? A pushed-out-of-line value is replaced by a 20-byte pointer structure. There's no such thing as partially out-of-line. See ht

Re: [GENERAL] schema 8.1.5

2006-10-26 Thread Alan Hodgson
On Thursday 26 October 2006 14:04, km <[EMAIL PROTECTED]> wrote: >> so that when the user logis in and accesses a database via psql he should > be able to land into his schema. how do i do that ? any tips ? alter role rolename set search_path=path1[,path2...]; -- Ginsberg's Theorem: 1) You can'

[GENERAL] schema 8.1.5

2006-10-26 Thread km
Hi all, Have a general doubt abt default schema public in postgresql 8.1.5: i would like to know if for every database a valid user creates, postgreSQL by default creates a public schema which is optional ? Also is it possible to know which schema i am currently in ? how do i set a user a

Re: [GENERAL] Effect of large text field data on queries

2006-10-26 Thread Tom Lane
Glen Parker <[EMAIL PROTECTED]> writes: > How much of a TOAST'd field is actually stored in the main heap table? > Is there a way to configure that amount? A pushed-out-of-line value is replaced by a 20-byte pointer structure. There's no such thing as partially out-of-line. See http://www.postgr

Re: [GENERAL] Effect of large text field data on queries

2006-10-26 Thread Alan Hodgson
On Thursday 26 October 2006 12:51, Glen Parker <[EMAIL PROTECTED]> wrote: > Why would very large text values effect the speed of a seq scan that > does not actually evaluate those values? Seq scan reads the whole table. The limiting factor is the size of the table on disk. -- "If a nation expe

Re: [GENERAL] Effect of large text field data on queries

2006-10-26 Thread Glen Parker
Tom Lane wrote: Glen Parker <[EMAIL PROTECTED]> writes: Why would very large text values effect the speed of a seq scan that does not actually evaluate those values? I'd actually suppose it's the smaller values (up to a few hundred bytes) that impact this the most. Really wide fields would be

Re: [GENERAL] Effect of large text field data on queries

2006-10-26 Thread Tom Lane
Glen Parker <[EMAIL PROTECTED]> writes: > Why would very large text values effect the speed of a seq scan that > does not actually evaluate those values? More bytes to scan over? Have you checked the physical table sizes? I'd actually suppose it's the smaller values (up to a few hundred bytes)

[GENERAL] Effect of large text field data on queries

2006-10-26 Thread Glen Parker
I am having some query problems on a table with large text fields. The table contains 6.7M rows. It is vacuumed every night, and since the last vacuum, rows have been inserted only, never updated or deleted. There are many large text field values in one text field, some in excess of 6MB. I

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread Tino Wildenhain
Ottavio Campana schrieb: Erik Jones wrote: Put them in arrays and pass them as the arguments. But, I would like to know what function could ever need 65 arguments? Consider that I have to invoke the function from a ZSQL method in zope. Do you know if it works? I need all these arguments beca

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread Ottavio Campana
I just implemented the same function using an array holding all the booleans fields describing the objects. It works well. Thank you to all of you. -- Non c'e' piu' forza nella normalita', c'e' solo monotonia. signature.asc Description: OpenPGP digital signature

[GENERAL] Compiling ELF 64-bit on Solaris

2006-10-26 Thread vodhner
How can I get the "make" to generate ELF 64-bit executables on Solaris 10? We're on Fujitsu hardware; uname -a displays this: SunOS 5.10 Generic_118822-26 sun4us sparc FJSV,GPUZC-M Thanks Victor Odhner ---(end of broadcast)--- TIP 1: if pos

Re: [GENERAL] UK Hosting Providers

2006-10-26 Thread John DeSoi
On Oct 26, 2006, at 7:46 AM, [EMAIL PROTECTED] wrote: Now they need someone to host the site, preferably UK based and not costing the earth supporting PHP and of course postgres. You might find some here: http://www.postgresql.org/support/professional_hosting John DeSoi, Ph.D. http://pg

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread Tom Lane
Ottavio Campana <[EMAIL PROTECTED]> writes: > I'm writing some stored procedures in pl/pgsql for a database using > postgresql 7.4.7. > I need to write a complex function with 65 arguments, but when I try to > run it I get an error complaining that arguments can be up to 32. Update to 8.1, which a

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread David Fetter
On Thu, Oct 26, 2006 at 10:03:27AM -0700, Ottavio Campana wrote: > I'm writing some stored procedures in pl/pgsql for a database using > postgresql 7.4.7. > > I need to write a complex function with 65 arguments, but when I try > to run it I get an error complaining that arguments can be up to 32.

Re: [GENERAL] Monitoring Postgres - Get the SQL queries which are sent to postgres

2006-10-26 Thread Vivek Khera
On Oct 25, 2006, at 10:11 AM, A. Kretschmer wrote: Set this in your postgresql.conf: log_statement = all Reload the server, and then you can find all your statements in the log. or, preferably, on a per-connection basis, execute this SQL statement: set log_min_duration_statement = 0 the

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread Volkan YAZICI
On Oct 26 10:55, Ottavio Campana wrote: > Erik Jones wrote: > > Put them in arrays and pass them as the arguments. But, I would like to > > know what function could ever need 65 arguments? > > Consider that I have to invoke the function from a ZSQL method in zope. > Do you know if it works? > >

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread Ottavio Campana
Erik Jones wrote: > Put them in arrays and pass them as the arguments. But, I would like to > know what function could ever need 65 arguments? Consider that I have to invoke the function from a ZSQL method in zope. Do you know if it works? I need all these arguments because we have a tables wher

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread Volkan YAZICI
On Oct 26 10:03, Ottavio Campana wrote: > I'm writing some stored procedures in pl/pgsql for a database using > postgresql 7.4.7. > > I need to write a complex function with 65 arguments, but when I try to > run it I get an error complaining that arguments can be up to 32. > > Is there a way to s

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread William Leite Araújo
Create a type whith the fields?! Ex.:     Create type myType as (field1 integer, field2 integer, ...);    Create or replace function func_type(myType) returns integer AS     $$     DECLARE    param ALIAS FOR $1;    BEGIN    RA

Re: [GENERAL] more than 32 parameters to a function?

2006-10-26 Thread Erik Jones
Put them in arrays and pass them as the arguments. But, I would like to know what function could ever need 65 arguments? Ottavio Campana wrote: I'm writing some stored procedures in pl/pgsql for a database using postgresql 7.4.7. I need to write a complex function with 65 arguments, but when

Re: [GENERAL] NOTICE: word is too long INSERT 0 3014

2006-10-26 Thread Joshua D. Drake
Any thoughts on the below? Joshua D. Drake wrote: > Hello, > > I am running into this limitation ALOT with Tsearch2. What are my > options to get around it. Do I have to compile PostgreSQL with a > different block size? > > If yes, what are the downsides to doing so (outside of not being able to

[GENERAL] more than 32 parameters to a function?

2006-10-26 Thread Ottavio Campana
I'm writing some stored procedures in pl/pgsql for a database using postgresql 7.4.7. I need to write a complex function with 65 arguments, but when I try to run it I get an error complaining that arguments can be up to 32. Is there a way to solve this problem or do I have to try to split the fun

Re: [GENERAL] grouping excluding some text results

2006-10-26 Thread John Sidney-Woollett
Off the top of my head (and not sure how optimized)... select t1.id, t1.score, t1.description from scoretable t1, ( select id, max(score) as score from scoretable group by id ) as t2 where t1.id = t2.id and t1.score = t2.score order by t1.id If you get duplicated rows back, then try using

[GENERAL] UK Hosting Providers

2006-10-26 Thread richard . day
Sorry to intrude on the community just to ask a dumb question, but I don't know postgres and I know how helpful and friendly newgroups are to ignorant newbies ;) I have a client who has had some software developed that requires a website element and the site uses postgres for the back end database

[GENERAL] grouping excluding some text results

2006-10-26 Thread Fip
Hi, ho can I select some one restult for type, excluding the rest? I have something like, as result of a join: | ID | score| description | - MG01 56 "textual description1..." MG02 47

[GENERAL] [Triggers] Check if OLD or NEW records are NULL

2006-10-26 Thread macieh
Dear All, Can I check if OLD record is NULL in trigger function. I'm using tg_op and check if it's UPDATE, etc. but I need check if OLD record exists. Is it possible? f.i. IF OLD IS NOT NULL THEN IF OLD.identity IS NULL THEN tg_op_final:=''INSE

[GENERAL] Updating client table definitions from server tables without losing client data

2006-10-26 Thread Roberto Hartke Neto
Hi...   I want to create an automatic update application. In this application, I need to update the database because new versions of a program may use newly created tables or modified tables, if compared to the older version program.   So, I have a database version 2.0 in Computer 'A', and

Re: [GENERAL] What is causing 'canceling statement due to user request' ?

2006-10-26 Thread Thomas Kellerer
On 23.10.2006 16:14 Csaba Nagy wrote: Hi all, I know of 2 causes: - hit CTRL-C in the psql client; - have a non-zero statement timeout and have the statement actually time out; But I am seeing this via JDBC which can't cancel a statement AFAIK JDBC *can* cancel a running statement. You jus

Re: [GENERAL] Wordpress & PostgreSQL ...

2006-10-26 Thread Robert Treat
the wordpress guys have basically said they do not want to support postgres, which is mainly why we swapped to s9y on planetpg. you can read some more info here: http://people.planetpostgresql.org/xzilla/index.php?/archives/13-One-Good-Port.html Robert Treat On Saturday 21 October 2006 23:31,

[GENERAL] PostgreSQL uses in the weather service

2006-10-26 Thread farhad . heybati
Hi All, I saw that "The National Weather Service" uses the PostgreSQL. I'm interested to implement the PostgreSql in the similar functional area and I need some experience feedback regard the database volume, the PostgreSQL performance in The National Weather Service. Thanks in advance, Best Reg

Re: [GENERAL] PostgreSQL in article I wrote

2006-10-26 Thread Walter Vaughan
Roman Neuhauser wrote regarding: http://www.sema.org/main/semaorghome.aspx?id=56095 The firefox / thunderbird section should rather warn them to pay attention to bugtraq. All those buffer overflows in libwhathaveyou will make sure their single-user (root) KDE installations will need

Re: [GENERAL] password cookie

2006-10-26 Thread Andrew Sullivan
On Thu, Oct 26, 2006 at 12:27:49AM +0200, Willy-Bas Loos wrote: > or will not receive those, because of the rights granted to him. These > granted rights and roles will be determined by the regular postgres > functionality (and some views). Ah, that's a different matter. My suggestion is "don't d

Re: [GENERAL] pg_dumpall failing from possible corrupted shared memory

2006-10-26 Thread Tom Lane
Richard Broersma Jr <[EMAIL PROTECTED]> writes: > I did not find any coredump files. Will I need to rebuild postgres to > produce coredumps? No, you just need to make sure the postmaster is started under "ulimit -c unlimited", not "ulimit -c 0" which is the default under many Linuxen. Adding th

Re: [GENERAL] Problem with 8.1.5 RPMs for Redhat AS 4

2006-10-26 Thread Devrim GUNDUZ
Hello, On Wed, 2006-10-25 at 13:41 -0500, Will Reese wrote: > Any idea when the new RPMs might be available for AS 4? Ah sorry. I just pushed them. They will be in main FTP site in an hour. It may take some time for your local mirror to pick it up. BTW, you can use RHEL ES 4 rpms for RHEL AS 4.

Re: [GENERAL] pg_autovacuum / pg_class

2006-10-26 Thread Alvaro Herrera
Tomas Vondra wrote: > Hello, > > I have a simple question about auto-vacuuming. We are running a Postgres > 8.1 and I've noticed that some of the tables are not analyzed by the > pg_autovacuum daemon. That is - when I select the rows from pg_class, > all the important values (relpages, reltuple

Re: [GENERAL] DBI-Link, Oracle, database encoding

2006-10-26 Thread Hannes Dorbath
I have it working fine now. Seems PG indeed did not have access to the env vars, because of the init script I was using. export NLS_LANG=AMERICAN_AMERICA.AL32UTF8 export NLS_NCHAR=AL32UTF8 pg_ctl restart fixed it for me. If you are using DBI-Link, please sign up for its mailing list on pgfoun

[GENERAL] pg_autovacuum / pg_class

2006-10-26 Thread Tomas Vondra
Hello, I have a simple question about auto-vacuuming. We are running a Postgres 8.1 and I've noticed that some of the tables are not analyzed by the pg_autovacuum daemon. That is - when I select the rows from pg_class, all the important values (relpages, reltuples) are 0. I've noticed this i

Re: [GENERAL] Reducing pg_dump & pg_restore times

2006-10-26 Thread Ron Johnson
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 10/26/06 01:20, Chris wrote: > Coder At Heart wrote: >> Hi! >> >> Restore & backup take time in the tune of 6 hrs on a Linux, 4 proc, 32 >> G RAM machine for a 60GB database. > > Please always cc the mailing list. > > I've never played with data

Re: [GENERAL] Enableing contrib modules on Debian

2006-10-26 Thread Stuart Grimshaw
On 10/25/06, Tom Lane <[EMAIL PROTECTED]> wrote: "Stuart Grimshaw" <[EMAIL PROTECTED]> writes: > I've installed the postgresql-contrib8.1 deb package to get at the > earthdistance function, but it doesn't seem to be recognised, even > after a restart of the server. > Is there a final step I need