Re: [HACKERS] binary representation of datatypes

2008-10-21 Thread Jeroen Vermeulen
Matthieu Imbert wrote: scenario 1 - parse the textual representation of all results of requests to the database and convert textual timestamps to a binary format that i choose among those ones (number of microseconds since 2000-01-01, or a structure similar to pg_tm (but with microsecond preci

Re: [HACKERS] Bitmap Indexes: request for feedback

2008-10-21 Thread Tom Lane
Gregory Stark <[EMAIL PROTECTED]> writes: > Josh Berkus <[EMAIL PROTECTED]> writes: >> The other major issue with the Bitmap index patch as it stood in 2007 was >> that performance just wasn't that much faster than a btree, except for >> specific corner cases. Otherwise, someone else would have

Re: [HACKERS] pg_ctl less than useful error message on windows when privileges wrong for postgres

2008-10-21 Thread Tom Lane
Dave Cramer <[EMAIL PROTECTED]> writes: > On 21-Oct-08, at 5:24 PM, Tom Lane wrote: >> It's fairly hard to see how that mistake leads to that symptom. >> Can you poke a bit more into exactly what is happening? > when I executed postgres.exe directly it complained of the user having > admin privs

Re: [HACKERS] Multi CPU Queries - Feedback and/or suggestions wanted!

2008-10-21 Thread Myron Scott
I can confirm that bringing Postgres code to multi-thread implementation requires quite a bit of ground work. I have been working for a long while with a Postgres 7.* fork that uses pthreads rather than processes. The effort to make all the subsystems thread safe took some time and touched

Re: [HACKERS] Bitmap Indexes: request for feedback

2008-10-21 Thread Gregory Stark
Josh Berkus <[EMAIL PROTECTED]> writes: > Gianni, > >> me and Gabriele Bartolini have been working on Bitmap Indexes (BMI) in >> the last weeks, with advice and guidance from Simon Riggs. We feel >> that we are about to approach the point where it is appropriate to ask >> for feedback from this li

Re: [HACKERS] Regression in IN( field, field, field ) performance

2008-10-21 Thread Gregory Stark
Tom Lane <[EMAIL PROTECTED]> writes: > Works fine for me, eg ... >-> Bitmap Heap Scan on tenk1 b (cost=0.79..4.82 rows=3 width=244) > Recheck Cond: (b.unique2 = ANY (ARRAY[a.unique1, a.ten, a.hundred])) > -> Bitmap Index Scan on tenk1_unique2 (cost=0.00..0.79 rows=3 > wi

Re: [HACKERS] Withdraw PL/Proxy from commitfest

2008-10-21 Thread Hannu Krosing
On Tue, 2008-10-21 at 21:05 +0300, Martin Pihlak wrote: > Hannu Krosing wrote: > > > In my brief reading of SQL-MED spec I could only find info on defining > > FOREIGN SERVER and FOREIGN-DATA WRAPPER and nowhere in these could one > > define connection parameters like username and password. > > I

Re: [HACKERS] pg_ctl less than useful error message on windows when privileges wrong for postgres

2008-10-21 Thread Dave Cramer
On 21-Oct-08, at 5:24 PM, Tom Lane wrote: Dave Cramer <[EMAIL PROTECTED]> writes: I have a client who mistakenly gave the postgres user on a windows machine admin privileges. This mistake results in the service being unable to start up due to postgres refusing to start with admin privileges

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Robert Haas
> Seems like we ought to clean this up. I'm not sure which way to jump > though: should we decree that arrays of no elements must always have > zero dimensions, or should we get rid of that and standardize on, say, > 1-D array with lower bound 1 and upper bound 0? Isn't the zero-dimensional array

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Merlin Moncure
On Tue, Oct 21, 2008 at 1:50 PM, Tom Lane <[EMAIL PROTECTED]> wrote: > Currently, the constructs >'{}'::arraytype >ARRAY[]::arraytype > return zero-dimensional arrays, as does the underlying function > construct_empty_array(). I can't immediately find any way at SQL > level to prod

Re: [HACKERS] pg_ctl less than useful error message on windows when privileges wrong for postgres

2008-10-21 Thread Tom Lane
Dave Cramer <[EMAIL PROTECTED]> writes: > I have a client who mistakenly gave the postgres user on a windows > machine admin privileges. > This mistake results in the service being unable to start up due to > postgres refusing to start with admin privileges. > The error message from pg_ctl st

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread David E. Wheeler
On Oct 21, 2008, at 14:16, Tom Lane wrote: Well, we can't do that because it would clearly break too much existing code. '{}' has got to result in something you can successfully concatenate more elements to. Right, that's what I was trying to day. Badly, I guess. But either the current be

Re: [HACKERS] Bitmap Indexes: request for feedback

2008-10-21 Thread Josh Berkus
Gianni, > me and Gabriele Bartolini have been working on Bitmap Indexes (BMI) in > the last weeks, with advice and guidance from Simon Riggs. We feel > that we are about to approach the point where it is appropriate to ask > for feedback from this list. The other major issue with the Bitmap index

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Tom Lane
"David E. Wheeler" <[EMAIL PROTECTED]> writes: > On Oct 21, 2008, at 13:58, Tom Lane wrote: >> Same as before, I think: initialize it to '{}'. What's at stake here >> is exactly what does that notation mean ... > An empty, single-dimension array. But I got the impression from Simon > that he th

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Josh Berkus
> An empty, single-dimension array. But I got the impression from Simon > that he thought it should be NULL. I disagree with Simon *if* that's what he's saying. '{}' isn't equivalent to NULL any more than 0 or '' is. NULL means "I don't know / Doesn't apply" wheras '{}' means "purposefully le

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread David E. Wheeler
On Oct 21, 2008, at 13:58, Tom Lane wrote: If we got rid of zero dimension arrays, how would I declare a new empty array in a PL/pgSQL function? Same as before, I think: initialize it to '{}'. What's at stake here is exactly what does that notation mean ... An empty, single-dimension array.

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Tom Lane
"David E. Wheeler" <[EMAIL PROTECTED]> writes: > If we got rid of zero dimension arrays, how would I declare a new > empty array in a PL/pgSQL function? Same as before, I think: initialize it to '{}'. What's at stake here is exactly what does that notation mean ... rega

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread David E. Wheeler
On Oct 21, 2008, at 13:00, Andrew Chernow wrote: On Oct 21, 2008, at 12:08, Simon Riggs wrote: If we got rid of zero dimension arrays, how would I declare a new empty array in a PL/pgSQL function? Why would you want to do that? Is there a use case for that? Perhaps not. In older versions

Re: [HACKERS] Multi CPU Queries - Feedback and/or suggestions wanted!

2008-10-21 Thread Julius Stroffek
Hi Jeffrey, thank you for the suggestion. Yes, they potentially can, we'll consider this. Julo Jeffrey Baker wrote: I don't see why multiple CPUs can't work on the same node of a plan. For instance, consider a node involving a scan with an expensive condition, like UTF-8 string length. If

Re: [HACKERS] Regression in IN( field, field, field ) performance

2008-10-21 Thread Tom Lane
Decibel! <[EMAIL PROTECTED]> writes: > On Oct 21, 2008, at 12:06 PM, Tom Lane wrote: >> "Jim 'Decibel!' Nasby" <[EMAIL PROTECTED]> writes: >>> Filter: ('xxx'::text = ANY ((ARRAY[home_phone, mobile_phone, >>> work_phone])::text[])) >> > Which means automatic seqscan. >> >> It means no such

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Andrew Chernow
David E. Wheeler wrote: On Oct 21, 2008, at 12:08, Simon Riggs wrote: If we got rid of zero dimension arrays, how would I declare a new empty array in a PL/pgSQL function? Why would you want to do that? Is there a use case for that? -- Andrew Chernow eSilo, LLC every bit counts http://www

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread David E. Wheeler
On Oct 21, 2008, at 12:08, Simon Riggs wrote: Please remove zero-dimension arrays. The number of dimensions of an empty array really ought to be NULL, or if we fix it to be non-NULL then 1+. Zero just makes a weird case for no reason. An empty string only makes sense in the context of that p

[HACKERS] pg_ctl less than useful error message on windows when privileges wrong for postgres

2008-10-21 Thread Dave Cramer
I have a client who mistakenly gave the postgres user on a windows machine admin privileges. This mistake results in the service being unable to start up due to postgres refusing to start with admin privileges. The error message from pg_ctl start -D bindir is PG_CTL.."could not locate mat

Re: [HACKERS] [COMMITTERS] pgsql: SQL 200N -> SQL:2003

2008-10-21 Thread Peter Eisentraut
On Tuesday 21 October 2008 19:59:02 Tom Lane wrote: > Simon Riggs <[EMAIL PROTECTED]> writes: > > On Mon, 2008-10-20 at 16:18 +0100, Simon Riggs wrote: > >> On Mon, 2008-10-20 at 14:26 +, Peter Eisentraut wrote: > >>> SQL 200N -> SQL:2003 > >> > >> Why not SQL:2008? > > > > Peter? > > If the co

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Simon Riggs
On Tue, 2008-10-21 at 13:50 -0400, Tom Lane wrote: > Currently, the constructs > '{}'::arraytype > ARRAY[]::arraytype > return zero-dimensional arrays, as does the underlying function > construct_empty_array(). I can't immediately find any way at SQL > level to produce an empty array

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Merlin Moncure
On Tue, Oct 21, 2008 at 2:23 PM, Tom Lane <[EMAIL PROTECTED]> wrote: > "Merlin Moncure" <[EMAIL PROTECTED]> writes: >> ISTM this is the way it should work from SQL level: > >> '{}'::int[] empty 1d >> '{{},{}}'::int[] :: empty 2d > > The first one looks okay, but ISTM the second one is not describin

Re: [HACKERS] Regression in IN( field, field, field ) performance

2008-10-21 Thread Decibel!
On Oct 21, 2008, at 12:06 PM, Tom Lane wrote: "Jim 'Decibel!' Nasby" <[EMAIL PROTECTED]> writes: WHERE 'xxx' IN (people.home_phone, people.work_phone, people.mobile_phone) Yeah, not exactly a common case, but at least in 8.1 this was turned into a set of ORs. Starting in 8.2 an

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Tom Lane
"Merlin Moncure" <[EMAIL PROTECTED]> writes: > ISTM this is the way it should work from SQL level: > '{}'::int[] empty 1d > '{{},{}}'::int[] :: empty 2d The first one looks okay, but ISTM the second one is not describing an "empty" array: the upper dimension is of length 2. In particular I think

Re: [HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Pavel Stehule
2008/10/21 Tom Lane <[EMAIL PROTECTED]>: > Currently, the constructs >'{}'::arraytype >ARRAY[]::arraytype > return zero-dimensional arrays, as does the underlying function > construct_empty_array(). I can't immediately find any way at SQL > level to produce an empty array with one

Re: [HACKERS] Withdraw PL/Proxy from commitfest

2008-10-21 Thread Martin Pihlak
Hannu Krosing wrote: > In my brief reading of SQL-MED spec I could only find info on defining > FOREIGN SERVER and FOREIGN-DATA WRAPPER and nowhere in these could one > define connection parameters like username and password. It is cleverly hidden. The CREATE SERVER and CREATE USER MAPPING take g

[HACKERS] So what's an "empty" array anyway?

2008-10-21 Thread Tom Lane
Currently, the constructs '{}'::arraytype ARRAY[]::arraytype return zero-dimensional arrays, as does the underlying function construct_empty_array(). I can't immediately find any way at SQL level to produce an empty array with one or more dimensions. However, construct_array and co

Re: [HACKERS] automatic parser generation for ecpg

2008-10-21 Thread Michael Meskes
On Tue, Oct 21, 2008 at 08:45:11AM -0700, David Fetter wrote: > > As against that ... does a2p produce code that is > > readable/maintainable? > > Not that I've seen. There are modules on CPAN (I know, I know) for > dealing with lexx and yacc, and those are probably better for the > purpose. Wel

[HACKERS] Buildfarm Cardinal going down.

2008-10-21 Thread Gevik Babakhani
I am going to do some hardware upgrading on buildfarm Cardinal. It will be down for sometime. Regards, Gevik -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Regression in IN( field, field, field ) performance

2008-10-21 Thread Tom Lane
"Jim 'Decibel!' Nasby" <[EMAIL PROTECTED]> writes: >WHERE '12814474045' IN (people.home_phone, people.work_phone, > people.mobile_phone) > Yeah, not exactly a common case, but at least in 8.1 this was turned > into a set of ORs. Starting in 8.2 and in current HEAD, the planner > turn

Re: [HACKERS] [COMMITTERS] pgsql: SQL 200N -> SQL:2003

2008-10-21 Thread Tom Lane
Simon Riggs <[EMAIL PROTECTED]> writes: > On Mon, 2008-10-20 at 16:18 +0100, Simon Riggs wrote: >> On Mon, 2008-10-20 at 14:26 +, Peter Eisentraut wrote: >>> SQL 200N -> SQL:2003 >> >> Why not SQL:2008? > Peter? If the comment was meant to refer to SQL:2003 originally, it should probably be

[HACKERS] double-buffering page writes

2008-10-21 Thread Alvaro Herrera
Hi, I'm trying to see if it makes sense to do the double-buffering of page writes before going further ahead with CRC checking. I came up with the attached patch; it does the double-buffering inconditionally, because as it was said, it allows releasing the io_in_progress lock (and resetting BM_IO

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Peter Eisentraut
On Tuesday 21 October 2008 15:47:35 Tom Lane wrote: > Gregory Stark <[EMAIL PROTECTED]> writes: > > Sort of. SSH requires you to install the certificate of the server > > locally before connecting. If you don't it pops up a big warning and asks > > if you want to install it. On subsequent connectio

[HACKERS] Regression in IN( field, field, field ) performance

2008-10-21 Thread Jim 'Decibel!' Nasby
WHERE '12814474045' IN (people.home_phone, people.work_phone, people.mobile_phone) Yeah, not exactly a common case, but at least in 8.1 this was turned into a set of ORs. Starting in 8.2 and in current HEAD, the planner turns that into: Filter: ('12814474045'::text = ANY ((ARRAY[hom

Re: [HACKERS] automatic parser generation for ecpg

2008-10-21 Thread David Fetter
On Tue, Oct 21, 2008 at 08:31:54AM -0400, Tom Lane wrote: > So it's all pretty messy and neither choice is exactly desirable. I > think maintaining parallel versions of an ecpg parser generator > would be no fun at all, though, so the perl choice seems more or > less forced. We could either pres

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Martijn van Oosterhout
On Tue, Oct 21, 2008 at 02:41:11PM +0300, Peter Eisentraut wrote: > >Preventing casual snooping without preventing MitM is a rational choice > >for system administrators. > > I am not an expert in these things, but it seems to me that someone who > can casually snoop can also casually insert DHCP

[HACKERS] Bitmap Indexes: request for feedback

2008-10-21 Thread Gianni Ciolli
Hi everybody, me and Gabriele Bartolini have been working on Bitmap Indexes (BMI) in the last weeks, with advice and guidance from Simon Riggs. We feel that we are about to approach the point where it is appropriate to ask for feedback from this list. Thank you, Dr. Gianni Ciolli - 2ndQuadrant It

Re: [HACKERS] Withdraw PL/Proxy from commitfest

2008-10-21 Thread Hannu Krosing
On Fri, 2008-09-05 at 15:39 +0300, Marko Kreen wrote: > In the previous discussion there was mentioned that Postgres should > move to the SQL-MED direction in remote connection handling. > > SQL-MED specifies that connections should have names and referenced > everywhere using names. Where did yo

Re: [HACKERS] automatic parser generation for ecpg

2008-10-21 Thread Tom Lane
Michael Meskes <[EMAIL PROTECTED]> writes: > ... The only manual work I see in the > future is adding some special ecpg handling. I fully expect this script to > generate a working parser for every single change in gram.y. However, if some > new rule needs a different aka non-default handling in ec

Re: [HACKERS] Hot Standby utility and administrator functions

2008-10-21 Thread Simon Riggs
On Tue, 2008-10-21 at 09:44 +0200, Zeugswetter Andreas OSB sIT wrote: > > > * pg_last_recovered_xact_xid() > > > Will throw an ERROR if *not* executed in recovery mode. > > > returns bigint > > > > > > * pg_last_completed_xact_xid() > > > Will throw an ERROR *if* executed in recovery mode. > > > r

Re: [HACKERS] minimal update

2008-10-21 Thread Andrew Dunstan
Tom Lane wrote: Magnus Hagander <[EMAIL PROTECTED]> writes: In that case, why not put the trigger in core so people can use it easily? One advantage of making it a contrib module is that discussing how/when to use it would fit more easily into the structure of the documentation. Th

Re: [HACKERS] corrupted pg_proc?

2008-10-21 Thread Pavel Stehule
Hello try to http://svana.org/kleptog/pgsql/pgfsck.html regards Pavel Stehule 2008/10/21 BRUSSER Michael <[EMAIL PROTECTED]>: > I need to repair the old version of Postgresql. > > pg_dump does not work, I tried few other things but could not come up with > any workable scenario. > > Any help wil

[HACKERS] Hot Standby: Caches and Locks

2008-10-21 Thread Simon Riggs
Next stage is handling locks and proc interactions. While this has been on Wiki for a while, I have made a few more improvements, so please read again now. Summary of Proposed Changes --- * New RMgr using rmid==8 => RM_RELATION_ID (which fills last gap) * Write new WAL me

Re: [HACKERS] binary representation of datatypes

2008-10-21 Thread Merlin Moncure
On Tue, Oct 21, 2008 at 4:21 AM, Matthieu Imbert <[EMAIL PROTECTED]> wrote: > Dear postgresql hackers, > > I would like to be able to get results from SQL commands directly in a > binary format, instead of a textual one. Actually, I want to be able to > get timestamps with their full precision (mic

Re: [HACKERS] binary representation of datatypes

2008-10-21 Thread Michael Meskes
On Tue, Oct 21, 2008 at 01:37:44PM +0200, Matthieu Imbert wrote: > Yes microseconds are available in textual mode but i do want to use binary > mode. Let me explain why: > ... > if i'm correct, it seems obvious that the second scenario is more efficient > (and less ugly). I wouldn't bet on scena

Re: [HACKERS] automatic parser generation for ecpg

2008-10-21 Thread Michael Meskes
I share Tom's thoughts completely. My personal goal is definitely to make ecpg parser generation a fully automated task. The only manual work I see in the future is adding some special ecpg handling. I fully expect this script to generate a working parser for every single change in gram.y. However,

Re: [HACKERS] minimal update

2008-10-21 Thread Tom Lane
Magnus Hagander <[EMAIL PROTECTED]> writes: > In that case, why not put the trigger in core so people can use it > easily? One advantage of making it a contrib module is that discussing how/when to use it would fit more easily into the structure of the documentation. There is no place in our do

Re: [HACKERS] minimal update

2008-10-21 Thread Merlin Moncure
On Tue, Oct 21, 2008 at 9:34 AM, Magnus Hagander <[EMAIL PROTECTED]> wrote: > On 20 okt 2008, at 16.51, Andrew Dunstan <[EMAIL PROTECTED]> wrote: >> >> No, it's not just a hack. It's very close to what we'd probably do if we >> built the facility right into the language, although it does involve th

Re: [HACKERS] minimal update

2008-10-21 Thread David Fetter
On Tue, Oct 21, 2008 at 03:34:04PM +0200, Magnus Hagander wrote: > On 20 okt 2008, at 16.51, Andrew Dunstan <[EMAIL PROTECTED]> wrote: >> Magnus Hagander wrote: >>> Andrew Dunstan wrote: Tom Lane wrote: > Andrew Dunstan <[EMAIL PROTECTED]> writes: >> OK. Where would be a good place to

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Andrew Sullivan
On Tue, Oct 21, 2008 at 08:47:35AM -0400, Tom Lane wrote: > Um, IIRC what it's checking there is the server's key signature, which > has nada to do with certificates. That depends on whether you used an X.509 certificate to authenticate the original signature. Just about nobody does, but AIUI, t

Re: [HACKERS] minimal update

2008-10-21 Thread Magnus Hagander
On 20 okt 2008, at 16.51, Andrew Dunstan <[EMAIL PROTECTED]> wrote: Magnus Hagander wrote: Andrew Dunstan wrote: Tom Lane wrote: Andrew Dunstan <[EMAIL PROTECTED]> writes: OK. Where would be a good place to put the code? Maybe a new file src/backend/utils/adt/trigger_utils.c ? I t

Re: [HACKERS] automatic parser generation for ecpg

2008-10-21 Thread Tom Lane
Mike Aubury <[EMAIL PROTECTED]> writes: > In reality - it doesn't look too disimilar from the awk original. I didn't > appreciate that we'd probably need to keep 2 versions (one for unix and one > for windows). In that case - I'd argue that we only need to "maintain" one > and regenerate the oth

Re: [HACKERS] pg_stat_statements in core

2008-10-21 Thread Tom Lane
ITAGAKI Takahiro <[EMAIL PROTECTED]> writes: >> Now I'm working on storing statistics into disks on server >> shutdown. If it is impossible unless the module is in core, >> I would change my policy... I'm really not happy with a proposal to put such a feature in core. Once it's in core we'll have

Re: [HACKERS] automatic parser generation for ecpg

2008-10-21 Thread Mike Aubury
Perl code thats readable and maintainable ;-) In reality - it doesn't look too disimilar from the awk original. I didn't appreciate that we'd probably need to keep 2 versions (one for unix and one for windows). In that case - I'd argue that we only need to "maintain" one and regenerate the oth

Re: [HACKERS] contrib/pg_stat_statements

2008-10-21 Thread Decibel!
On Oct 17, 2008, at 4:30 AM, Vladimir Sitnikov wrote: Decibel! <[EMAIL PROTECTED]> wrote: I had tried to use a normal table for store stats information, but several acrobatic hacks are needed to keep performance. I guess it is not really required to synchronize the stats into some physical tab

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Tom Lane
Gregory Stark <[EMAIL PROTECTED]> writes: > Sort of. SSH requires you to install the certificate of the server locally > before connecting. If you don't it pops up a big warning and asks if you want > to install it. On subsequent connections it looks up the key for the name of > the host you're try

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Gregory Stark
Martijn van Oosterhout <[EMAIL PROTECTED]> writes: > SSH is a good example, it only works with self-signed certificates, and > relies on the client to check it. Libpq provides a mechanism for the > client to verify the server's certificate, and that is safe even if it > is self-signed. Sort of. S

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Magnus Hagander
On 21 okt 2008, at 13.41, Peter Eisentraut <[EMAIL PROTECTED]> wrote: Martijn van Oosterhout wrote: SSH is a good example, it only works with self-signed certificates, and relies on the client to check it. Libpq provides a mechanism for the client to verify the server's certificate, and t

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Magnus Hagander
On 21 okt 2008, at 13.41, Peter Eisentraut <[EMAIL PROTECTED]> wrote: Martijn van Oosterhout wrote: SSH is a good example, it only works with self-signed certificates, and relies on the client to check it. Libpq provides a mechanism for the client to verify the server's certificate, and t

Re: [HACKERS] automatic parser generation for ecpg

2008-10-21 Thread Tom Lane
Mike Aubury <[EMAIL PROTECTED]> writes: > Also - for completeness (for the list) - I think the plan is to convert the > awk to perl (via a2p + some tweaking) if awk is not already used as part of > the build process (to avoid adding another prerequisite..) Hmm. I believe the current state of p

[HACKERS] TSEARCH2 Thesaurus limitations

2008-10-21 Thread Theodore Wong
Hi, I'm new to Postgres and would appreciate some help in understanding what the limitations of TSEARCH2 and the Thesauri operation. I'm trying to use the thesaurus as a geo-tagger/coder. The first part of the problem is to create placename list with additional information such as state, county

Re: [GENERAL] [HACKERS] Hot Standby utility and administrator functions

2008-10-21 Thread Tom Lane
Simon Riggs <[EMAIL PROTECTED]> writes: > On Mon, 2008-10-20 at 18:45 -0400, Tom Lane wrote: >> In any case, do not use the wrong return type for the definition you're >> implementing. > err...Why would anyone do that? That's what I wanted to know ;-). If these functions are really going to retu

Re: [HACKERS] SE-PostgreSQL wiki updates, but ...

2008-10-21 Thread KaiGai Kohei
Stefan Kaltenbrunner wrote: Hitoshi Harada wrote: 2008/10/21 KaiGai Kohei <[EMAIL PROTECTED]>: Is it possiblt to host it on the wiki.postgresql.org? If possible, I want to continue it at: http://wiki.postgresql.org/wiki/SEPostgreSQL Though I don't know if this is official way, I found that

[HACKERS] corrupted pg_proc?

2008-10-21 Thread BRUSSER Michael
I need to repair the old version of Postgresql. pg_dump does not work, I tried few other things but could not come up with any workable scenario. Any help will be greatly appreciated! Thanks, Michael. cdb=# vacuum; WARNING: Rel pg_proc: TID 31/20: OID IS INVALID. TUPGONE 0. VACUUM cd

[HACKERS] TSEARCH2 Thesaurus limitations

2008-10-21 Thread Ted Wong
Hi, I'm new to Postgres and would appreciate some help in understanding what the limitations of TSEARCH2 and the Thesauri operation. I'm trying to use the thesaurus as a geo-tagger/coder. The first part of the problem is to create placename list with additional information such as state, county

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Peter Eisentraut
Martijn van Oosterhout wrote: SSH is a good example, it only works with self-signed certificates, and relies on the client to check it. Libpq provides a mechanism for the client to verify the server's certificate, and that is safe even if it is self-signed. If the client knows the certificate th

Re: [HACKERS] binary representation of datatypes

2008-10-21 Thread Matthieu Imbert
Michael Meskes wrote: > On Tue, Oct 21, 2008 at 10:21:38AM +0200, Matthieu Imbert wrote: >> I would like to be able to get results from SQL commands directly in a >> binary format, instead of a textual one. Actually, I want to be able to >> get timestamps with their full precision (microsecond). >

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Magnus Hagander
On 21 okt 2008, at 13.12, Martijn van Oosterhout <[EMAIL PROTECTED]> wrote: On Tue, Oct 21, 2008 at 11:55:32AM +0100, Gregory Stark wrote: Martijn van Oosterhout <[EMAIL PROTECTED]> writes: You seem to be making the assertion that making an encrypted connection to an untrusted server is wo

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Martijn van Oosterhout
On Tue, Oct 21, 2008 at 11:55:32AM +0100, Gregory Stark wrote: > Martijn van Oosterhout <[EMAIL PROTECTED]> writes: > > > You seem to be making the assertion that making an encrypted connection > > to an untrusted server is worse than making a plaintext connection to > > an untrusted server, which

Re: [HACKERS] SE-PostgreSQL wiki updates, but ...

2008-10-21 Thread Stefan Kaltenbrunner
Hitoshi Harada wrote: 2008/10/21 KaiGai Kohei <[EMAIL PROTECTED]>: Is it possiblt to host it on the wiki.postgresql.org? If possible, I want to continue it at: http://wiki.postgresql.org/wiki/SEPostgreSQL Though I don't know if this is official way, I found that you can register a new accou

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Gregory Stark
Martijn van Oosterhout <[EMAIL PROTECTED]> writes: > You seem to be making the assertion that making an encrypted connection > to an untrusted server is worse than making a plaintext connection to > an untrusted server, which seems bogus to me. Hm, is it? If you use good old traditional telnet y

Re: [HACKERS] Index use during Hot Standby

2008-10-21 Thread Simon Riggs
On Tue, 2008-10-21 at 14:11 +0400, Teodor Sigaev wrote: > > I guess we'd use the same technique for GIN. ginInsertValue() ?? > > Hmm, you release the lock at line 412, ginbtree.c before you get the > > parent lock at line 428. That seems different to the L&Y interactions. > > Am I looking in the w

Re: [HACKERS] SE-PostgreSQL wiki updates, but ...

2008-10-21 Thread Hitoshi Harada
2008/10/21 KaiGai Kohei <[EMAIL PROTECTED]>: > Is it possiblt to host it on the wiki.postgresql.org? > If possible, I want to continue it at: > http://wiki.postgresql.org/wiki/SEPostgreSQL > Though I don't know if this is official way, I found that you can register a new account on http://www.po

Re: [HACKERS] automatic parser generation for ecpg

2008-10-21 Thread Mike Aubury
> (Mike, it lacks a copyright notice, I take it BSD is okay). Thats fine with me.. Also - for completeness (for the list) - I think the plan is to convert the awk to perl (via a2p + some tweaking) if awk is not already used as part of the build process (to avoid adding another prerequisite..)

Re: [HACKERS] Index use during Hot Standby

2008-10-21 Thread Teodor Sigaev
I guess we'd use the same technique for GIN. ginInsertValue() ?? Hmm, you release the lock at line 412, ginbtree.c before you get the parent lock at line 428. That seems different to the L&Y interactions. Am I looking in the wrong place? at line 412 new page (right page) is unlocked, old page (l

[HACKERS] SE-PostgreSQL wiki updates, but ...

2008-10-21 Thread KaiGai Kohei
I started to rework the SE-PostgreSQL documentation to catch up the latest implementation, because the existing PDF documents are a bit legacy to be updated. In addition, I moved them to wiki site for easier future updates. http://code.google.com/p/sepgsql/wiki/TheSepgsqlDocument However, I hav

Re: [HACKERS] binary representation of datatypes

2008-10-21 Thread Michael Meskes
On Tue, Oct 21, 2008 at 10:21:38AM +0200, Matthieu Imbert wrote: > I would like to be able to get results from SQL commands directly in a > binary format, instead of a textual one. Actually, I want to be able to > get timestamps with their full precision (microsecond). Are you sure you cannot get

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Martijn van Oosterhout
On Tue, Oct 21, 2008 at 11:02:11AM +0300, Peter Eisentraut wrote: > If you install a new web browser, would you want it to be configured by > default to warn about untrusted certificates or to "not bother" the user > about it? It's pretty much the same question here. We "don't bother" users whe

[HACKERS] binary representation of datatypes

2008-10-21 Thread Matthieu Imbert
Dear postgresql hackers, I would like to be able to get results from SQL commands directly in a binary format, instead of a textual one. Actually, I want to be able to get timestamps with their full precision (microsecond). googling around i found some threads on this mailing list about this: htt

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Greg Stark
Then they may as well not have bothered with generating a key in the first place since an attacker can generate one of his own just as easily... Actually that's not entirely true. A non-authenticated connection still protects against passive attacks like sniffers. But active attacks are k

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Magnus Hagander
On 21 okt 2008, at 10.04, Peter Eisentraut <[EMAIL PROTECTED]> wrote: Magnus Hagander wrote: Robert Haas wrote: How can you make that the default? Won't it immediately break every installation without certificates? *all* SSL installations have certificate on the server side. You cannot r

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Peter Eisentraut
Magnus Hagander wrote: Robert Haas wrote: How can you make that the default? Won't it immediately break every installation without certificates? *all* SSL installations have certificate on the server side. You cannot run without it. s/without certificates/with self-signed certificates/ which

Re: [HACKERS] SSL cleanups/hostname verification

2008-10-21 Thread Peter Eisentraut
Robert Haas wrote: How can you make that the default? Won't it immediately break every installation without certificates? *all* SSL installations have certificate on the server side. You cannot run without it. s/without certificates/with self-signed certificates/ which I would guess to be a

Re: [HACKERS] Hot Standby utility and administrator functions

2008-10-21 Thread Zeugswetter Andreas OSB sIT
> > * pg_last_recovered_xact_xid() > > Will throw an ERROR if *not* executed in recovery mode. > > returns bigint > > > > * pg_last_completed_xact_xid() > > Will throw an ERROR *if* executed in recovery mode. > > returns bigint > > Should these return xid? And shouldn't these two be folded togeth

Re: [HACKERS] Debian no longer dumps cores?

2008-10-21 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Mon, Oct 20, 2008 at 05:49:04PM -0300, Alvaro Herrera wrote: > Hi, > > My Debian system (now running Linux 2.6.26) is no longer dumping core > files, and I can't figure out why :-( Tested now with 2.6.25-2. Coredumps still work there. I submitted

Re: [GENERAL] [HACKERS] Hot Standby utility and administrator functions

2008-10-21 Thread Simon Riggs
On Mon, 2008-10-20 at 18:45 -0400, Tom Lane wrote: > Simon Riggs <[EMAIL PROTECTED]> writes: > > On Mon, 2008-10-20 at 17:44 -0300, Alvaro Herrera wrote: > >> That's been "extended with an epoch counter" per the docs; I don't think > >> that's appropriate for the new functions, is it? > > > I ass