Re: [HACKERS] contrib/rtree_gist into core system?

2005-06-27 Thread Greg Stark
Tom Lane [EMAIL PROTECTED] writes: John Hansen [EMAIL PROTECTED] writes: Simplicity! Implementing rtree operators and support functions is FAR simpler than implementing the GiST equivalents. Mmm ... not really. It does seem that we could offer some sort of generic set of gist

Re: [HACKERS] Sigh, another contrib/cube and contrib/seg problem

2005-06-27 Thread Andrew - Supernews
On 2005-06-27, Tom Lane [EMAIL PROTECTED] wrote: I just noticed that these two modules define operator @ as contains and operator ~ as contained by, which is opposite to the meanings used by every other datatype. These operators are fundamentally confusing because they give no visual

Re: [HACKERS] contrib/rtree_gist into core system?

2005-06-27 Thread Andrew - Supernews
On 2005-06-27, Greg Stark [EMAIL PROTECTED] wrote: I believe all the picksplit functions are based on (apparently via copy/paste) a single algorithm that depends on a single operator: a kind of distance function. Usually it's the same function underlying the penalty gist api function. That's

Re: [HACKERS] Implementing SQL/PSM for PG 8.2

2005-06-27 Thread Denis Lussier
Title: Re: [HACKERS] Implementing SQL/PSM for PG 8.2 Hi Affan, Please read this SQL/PSM thread over and then address how EDB did it (and of course how you would recommend generalizing it for PG 8.2). Perhaps our SQL/PSM could be designed from the ground up with "debugability" :-) in

Re: [HACKERS] contrib/rtree_gist into core system?

2005-06-27 Thread Teodor Sigaev
We can make r-tree as contrib module and then we will have example of index in contrib... By integrating the opclasses needed to replace R-tree, we can start down the path to deprecating and eventually removing R-tree. -- Teodor Sigaev E-mail: [EMAIL

[HACKERS] How two perform TPC-H test on postgresql-8.0.2

2005-06-27 Thread innodb
Currently I want to take a TPC-H test on postgresql-8.0.2. I have downloaded the DBGEN and QGEN from the homepage of TPC. But I encountered many problems which forced me to request some help. 1. How to load the data from flat file generated by dbgen tool? To the best of my

Re: [HACKERS] How two perform TPC-H test on postgresql-8.0.2

2005-06-27 Thread Neil Conway
innodb wrote: Currently I want to take a TPC-H test on postgresql-8.0.2. You might want to take a look at the TPC-H implementation here: http://www.osdl.org/lab_activities/kernel_testing/osdl_database_test_suite/osdl_dbt-3/ -Neil ---(end of

Re: [HACKERS] contrib/rtree_gist into core system?

2005-06-27 Thread Teodor Sigaev
FYI, compress and decompress methods may be trivial. For GiST you still need 7 support functions + the operator function, some of which aren't exactly simple to implement, the picksplit for instance. -- Teodor Sigaev E-mail: [EMAIL PROTECTED]

Re: [HACKERS] [SQL] ARRAY() returning NULL instead of ARRAY[]

2005-06-27 Thread Bruce Momjian
OK, what is the TODO item text? --- Joe Conway wrote: Bruce Momjian wrote: Is this a TODO item? Probably. I posted some questions regarding whether or not to break backward compatiblity, and received no replies.

[HACKERS] Constraint Exclusion (Partitioning)

2005-06-27 Thread Simon Riggs
Recently submitted to -patches. Copied here for further discussion. On Mon, 2005-06-27 at 01:41 +0100, Simon Riggs wrote: I enclose a fully working implementation of Constraint Exclusion, a very basic form of Partitioning. Initial review is requested, to allow us all to assess what further

Re: [HACKERS] [PATCHES] Cleaning up unreferenced table files

2005-06-27 Thread Bruce Momjian
Heikki, do you have any interest in completing your file checking patch for inclusion in 8.1 by adding tablespace information and other fixes as requested by Tom below? The current patch version is at: ftp://candle.pha.pa.us/pub/postgresql/mypatches called checkfiles*. Anyone else

[HACKERS] accessing postgres conf from stored procedure

2005-06-27 Thread strk
Is it possible to access postgres configuration from a C stored procedure ? I need to leverage memory usage and I'd use postgres configuration rather then a compile-time define. Is there such a configuration, if access is possible ? --strk; ---(end of

Re: [HACKERS] contrib/rtree_gist into core system?

2005-06-27 Thread John Hansen
Tom Lane [mailto:[EMAIL PROTECTED] Wrote: There's no HOWTO for rtree either. Again, my point is not that one couldn't be written; it's that we would probably be better off spending the effort on a HOWTO for gist. No, but the _current_ implementation of the rtree operators are ver much self

Re: [HACKERS] How two perform TPC-H test on postgresql-8.0.2

2005-06-27 Thread Andrew Dunstan
innodb wrote: Currently I want to take a TPC-H test on postgresql-8.0.2. I have downloaded the DBGEN and QGEN from the homepage of TPC. But I encountered many problems which forced me to request some help. 1. How to load the data from flat file generated by dbgen tool? To the

[HACKERS] GiST concurrency commited

2005-06-27 Thread Teodor Sigaev
Have we list named something like 'test focusing for 8.1'? If it exists then GiST concurrency and recovery testing should be added to it. Especially, recovery after crash. Of course, now Oleg and me going to begin a large test program. While I'm running test with concurrent

Re: [HACKERS] accessing postgres conf from stored procedure

2005-06-27 Thread Dave Cramer
you can use show xxx to show configuration values http://www.postgresql.org/docs/7.4/interactive/sql-show.html Dave On 27-Jun-05, at 6:56 AM, strk wrote: Is it possible to access postgres configuration from a C stored procedure ? I need to leverage memory usage and I'd use postgres

[HACKERS] tsearch2 vs core?

2005-06-27 Thread Magnus Hagander
Hi! Now that we have both WAL logging and better concurrency for GiST indexes (great job btw, this will push at least one of my projects into using 8.1 the day it is released - or more likely, at RC stage), are there any plans to move tsearch2 from contrib to core? I quite often hear from people

[HACKERS] Questions on extending a relation

2005-06-27 Thread Qingqing Zhou
Hi Hackers, Here I have two questions related to extending a relation: 1. When we want a new page, we will do something like this: LockPage(relation, 0, ExclusiveLock); blockNum = smgrnblocks(reln-rd_smgr); /* Try to locate this blockNum in buffer pool, but definitely can't? */

Re: [HACKERS] contrib/rtree_gist into core system?

2005-06-27 Thread Tom Lane
John Hansen [EMAIL PROTECTED] writes: No, but the _current_ implementation of the rtree operators are ver much self explaining and need no howto. That reasoning no doubt explains why we don't have *any* rtree-like opclasses that got the left/overleft/right/overright semantics right the first

Re: [HACKERS] process crash when a plpython function returns unicode

2005-06-27 Thread Michael Fuhr
On Sat, Jun 18, 2005 at 05:27:28PM +0200, Tino Wildenhain wrote: Am Samstag, den 18.06.2005, 08:41 -0600 schrieb Michael Fuhr: I was going to submit a patch, but I don't know enough about the Python API or how Python and PostgreSQL handle Unicode to know whether adding that simple check

Re: [HACKERS] GiST concurrency commited

2005-06-27 Thread Tom Lane
Teodor Sigaev [EMAIL PROTECTED] writes: While I'm running test with concurrent select/insert/update/delete/vacuum/vacuum full I found, that sometimes postgres crashes in index_beginscan_internal on FunctionCall3, because structure 'procedure' becomes zeroed. As I understand, LockRelation can

Re: [HACKERS] accessing postgres conf from stored procedure

2005-06-27 Thread strk
On Mon, Jun 27, 2005 at 08:55:50AM -0400, Dave Cramer wrote: you can use show xxx to show configuration values http://www.postgresql.org/docs/7.4/interactive/sql-show.html No direct interface for shared libs ? --strk; ---(end of broadcast)---

Re: [HACKERS] Questions on extending a relation

2005-06-27 Thread Tom Lane
Qingqing Zhou [EMAIL PROTECTED] writes: 1. When we want a new page, we will do something like this: LockPage(relation, 0, ExclusiveLock); blockNum = smgrnblocks(reln-rd_smgr); /* Try to locate this blockNum in buffer pool, but definitely can't? */ smgrextend(blockNum); LockPage(relation, 0,

Re: [HACKERS] accessing postgres conf from stored procedure

2005-06-27 Thread Michael Fuhr
On Mon, Jun 27, 2005 at 04:37:11PM +0200, strk wrote: On Mon, Jun 27, 2005 at 08:55:50AM -0400, Dave Cramer wrote: you can use show xxx to show configuration values http://www.postgresql.org/docs/7.4/interactive/sql-show.html No direct interface for shared libs ? I don't know if it's

Re: [HACKERS] Fixing r-tree semantics

2005-06-27 Thread Bruno Wolff III
On Sun, Jun 26, 2005 at 09:52:03 -0400, Tom Lane [EMAIL PROTECTED] wrote: Now that the module uses GIST instead of r-tree, there's no very strong reason why it should provide these operators at all. I propose removing all of from contrib/cube, leaving only the four n-dimensional

[HACKERS] For review: dbsize patch

2005-06-27 Thread Dave Page
The attached patch is an update of the dbsize integration patch discussed last week. This version includes the following functions: pg_relation_size(text) - Get relation size by name/schema.name pg_relation_size(oid)- Get relation size by OID pg_tablespace_size(name) - Get tablespace size

Re: [HACKERS] tsearch2 vs core?

2005-06-27 Thread Teodor Sigaev
Now that we have both WAL logging and better concurrency for GiST indexes (great job btw, this will push at least one of my projects into using 8.1 the day it is released - or more likely, at RC stage), are there any plans to move tsearch2 from contrib to core? tsearch2 now doesn't support

Re: [HACKERS] tsearch2 vs core?

2005-06-27 Thread Magnus Hagander
Now that we have both WAL logging and better concurrency for GiST indexes (great job btw, this will push at least one of my projects into using 8.1 the day it is released - or more likely, at RC stage), are there any plans to move tsearch2 from contrib to core? tsearch2 now doesn't

Re: [HACKERS] For review: dbsize patch

2005-06-27 Thread Michael Paesold
Dave Page wrote: The only remaining function that last week's brief discussion indicated was required is a replacement for total_relation_size() (or pg_table_size() as it might now be called). I didn't realise until a few minutes ago that this function (which is actually broken because it

Re: [HACKERS] Fixing r-tree semantics

2005-06-27 Thread Tom Lane
Bruno Wolff III [EMAIL PROTECTED] writes: I seem to remember there being a problem if , =, and = operators didn't exist and doing some operations (distinct or group by?) that required sorting the data type. I am not sure that you are suggesting that these operators be removed, No, I wasn't.

Re: [HACKERS] tsearch2 vs core?

2005-06-27 Thread Josh Berkus
Magnus, I quite often hear from people who miss it out because it's in contrib and not in main pg. Probably mainly because there is nothing about it in our docs. (other than in the list of examples for GiST, which probably directs more people into thinking it's just an example and not a

Re: [HACKERS] How two perform TPC-H test on postgresql-8.0.2

2005-06-27 Thread Josh Berkus
Inno, Currently I want to take a TPC-H test on postgresql-8.0.2. I have downloaded the DBGEN and QGEN from the homepage of TPC. But I encountered many problems which forced me to request some help. 1. How to load the data from flat file generated by dbgen tool? To the best of my

Re: [HACKERS] Sigh, another contrib/cube and contrib/seg problem

2005-06-27 Thread Josh Berkus
Andrew, I'd consider replacing them with something clearer, perhaps @ and @ ? (i.e. (a @ b) would mean a is contained by b and (a @ b) would mean a contains b) Ltree uses those operators in that way, I believe. -- Josh Berkus Aglio Database Solutions San Francisco

Re: [HACKERS] [PATCHES] Cleaning up unreferenced table files

2005-06-27 Thread Heikki Linnakangas
No, not for now. Maybe for 8.2. And maybe as a contrib tool at first after all. - Heikki On Mon, 27 Jun 2005, Bruce Momjian wrote: Heikki, do you have any interest in completing your file checking patch for inclusion in 8.1 by adding tablespace information and other fixes as requested by

Re: [HACKERS] tsearch2 vs core?

2005-06-27 Thread Oleg Bartunov
Magnus, we have pretty big TODO for tsearch2 http://www.sai.msu.su/~megera/postgres/gist/tsearch/V2/donate.shtml which we'd like to have implement once we get support. It's certainly not for 8.1. Oleg On Mon, 27 Jun 2005, Magnus Hagander wrote: Hi! Now that we have both WAL logging

Re: [HACKERS] Implementing SQL/PSM for PG 8.2

2005-06-27 Thread Jan Wieck
On 6/26/2005 4:10 PM, Pavel Stehule wrote: On Sun, 26 Jun 2005, Tom Lane wrote: Denis Lussier [EMAIL PROTECTED] writes: For various technical and backward compatibility reasons, I don't think SQL/PSM should be a replacement for PL/pgSQL. Although I do think it should heavily leverage the

Re: [HACKERS] Problem with dblink regression test

2005-06-27 Thread Jim C. Nasby
On Mon, Jun 27, 2005 at 02:10:47PM -0500, Jim C. Nasby wrote: http://stats.distributed.net/~buildfarm/libcheck.log. Note that Tom's theory is correct: psql is linking against the buildfarm libpq while dblink is linking against the system one. BTW, after looking through that logfile, it appears

Re: [HACKERS] Problem with dblink regression test

2005-06-27 Thread Andrew Dunstan
Jim C. Nasby wrote: On Mon, Jun 27, 2005 at 02:10:47PM -0500, Jim C. Nasby wrote: http://stats.distributed.net/~buildfarm/libcheck.log. Note that Tom's theory is correct: psql is linking against the buildfarm libpq while dblink is linking against the system one. BTW, after looking

Re: [HACKERS] Implementing SQL/PSM for PG 8.2

2005-06-27 Thread Jonah H. Harris
I agree with Jan, As part of my own projects I had to deal with the PL/pgSQL parser. While it was a workable design at the beginning, it now makes some things harder with the quoting etc. Don't get me wrong, I've never really had any beef with PL/pgSQL, it has worked great for a long time

Re: [HACKERS] Problem with dblink regression test

2005-06-27 Thread Jim C. Nasby
On Mon, Jun 27, 2005 at 03:44:41PM -0400, Andrew Dunstan wrote: Jim C. Nasby wrote: On Mon, Jun 27, 2005 at 02:10:47PM -0500, Jim C. Nasby wrote: http://stats.distributed.net/~buildfarm/libcheck.log. Note that Tom's theory is correct: psql is linking against the buildfarm libpq

[HACKERS] GCC pointer signedness (and other) warnings

2005-06-27 Thread Michael Glaesemann
I've noticed a lot of signedness warnings when compiling Postgres with GCC 4. They may have been there with GCC 3.3 as well, but I don't recall. Here's a example: gcc -no-cpp-precomp -O2 -Wall -Wmissing-prototypes -Wpointer-arith - Wdeclaration-after-statement -Wold-style-definition

[HACKERS] Wierd panic with 7.4.7

2005-06-27 Thread Joshua D. Drake
Hello, Any thoughts on the below? Specifically the PANIC? A customer was performing a full vacuum when it happen. This is running 7.4.7 on ES 3.0. We run daily vacuums and analyzes as well. 2005-06-27 16:35:02 LOG: recycled transaction log file 004D006F 2005-06-27 16:35:02 LOG:

Re: [HACKERS] For review: Server instrumentation patch

2005-06-27 Thread Andreas Pflug
Dave Page wrote: As per Bruce's request, here's a copy of Andreas' server instrumentation patch for review. I've separated out the dbsize stuff and pg_terminate_backend is also not included. This version was generated against CVS today. As far as I can tell from review of comments made back to

Re: [HACKERS] tsearch2 vs core?

2005-06-27 Thread Hiroshi Saito
From: Teodor Sigaev [EMAIL PROTECTED] Now that we have both WAL logging and better concurrency for GiST indexes (great job btw, this will push at least one of my projects into using 8.1 the day it is released - or more likely, at RC stage), are there any plans to move tsearch2 from

[HACKERS] Moving sequences to another schema

2005-06-27 Thread Bernd Helmle
I'm still playing around with the ALTER OBJECT SET SCHEMA stuff. I managed to alter indexes and constraints as well for tables, but with SERIAL sequences there is one little problem: When altering a sequence created by a SERIAL column type (i do this by examining pg_depend to avoid moving any

Re: [HACKERS] For review: dbsize patch

2005-06-27 Thread Bruce Momjian
Dave Page wrote: The attached patch is an update of the dbsize integration patch discussed last week. This version includes the following functions: pg_relation_size(text) - Get relation size by name/schema.name pg_relation_size(oid)- Get relation size by OID pg_tablespace_size(name)

Re: [HACKERS] Implementing SQL/PSM for PG 8.2

2005-06-27 Thread Neil Conway
Jonah H. Harris wrote: I don't recommend discussion for this in this thread, but it could also tie in with the packages support we've discussed and (although some may argue this), compiling the PL to bytecode and using that. How would compilation to bytecode help? -Neil

Re: [HACKERS] Implementing SQL/PSM for PG 8.2

2005-06-27 Thread Neil Conway
Jan Wieck wrote: The whole parser is a hack that attempts to parse the procedural parts of the function but preserving the SQL parts as query strings while substituting variables with numbered parameters. That is anything but clean. It was the only way I saw at the time of implementation to

[HACKERS] language handlers in public schema

2005-06-27 Thread Andrew Dunstan
This patch implements putting language handlers for the optional PLs into pg_catalog rather than public, and supports dumping languages whose handlers are found there. This will make it easier to drop the public schema if desired. Unlike the previous patch, the comments have been updated

Re: [HACKERS] Implementing SQL/PSM for PG 8.2

2005-06-27 Thread Rod Taylor
On Tue, 2005-06-28 at 10:40 +1000, Neil Conway wrote: Jan Wieck wrote: The whole parser is a hack that attempts to parse the procedural parts of the function but preserving the SQL parts as query strings while substituting variables with numbered parameters. That is anything but clean.

Re: [HACKERS] commit_delay, siblings

2005-06-27 Thread Bruce Momjian
Josh Berkus wrote: Hackers: I've been trying to get a test result for 8.1 that shows that we can eliminate commit_delay and commit_siblings, as I believe that these settings no longer have any real effect on performance. However, the checkpointing performance issues have so far

Re: [HACKERS] Moving sequences to another schema

2005-06-27 Thread Alvaro Herrera
On Tue, Jun 28, 2005 at 01:43:27AM +0200, Bernd Helmle wrote: When altering a sequence created by a SERIAL column type (i do this by examining pg_depend to avoid moving any other sequences that are 'foreign'), i need to recreate the default expression for the SERIAL column (stored in

Re: [HACKERS] GiST concurrency commited

2005-06-27 Thread Christopher Kings-Lynne
I think the whole GiST limitations page can be removed now... http://developer.postgresql.org/docs/postgres/limitations.html Chris ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an

Re: [HACKERS] Moving sequences to another schema

2005-06-27 Thread Christopher Kings-Lynne
When altering a sequence created by a SERIAL column type (i do this by examining pg_depend to avoid moving any other sequences that are 'foreign'), i need to recreate the default expression for the SERIAL column (stored in pg_attrdef.adbin). Is there an API to do that, or do i have to recreate

Re: [HACKERS] Implementing SQL/PSM for PG 8.2

2005-06-27 Thread Christopher Browne
A long time ago, in a galaxy far, far away, [EMAIL PROTECTED] (Jonah H. Harris) wrote: I don't recommend discussion for this in this thread, but it could also tie in with the packages support we've discussed and (although some may argue this), compiling the PL to bytecode and using that. This

Re: [HACKERS] Questions on extending a relation

2005-06-27 Thread Qingqing Zhou
Tom Lane [EMAIL PROTECTED] writes Yes. That's intentional --- otherwise they'd all block each other. So if I saw the last two pages on a disk relation are half full, that's nothing wrong? Why wouldn't we replay xlog? Note in particular that the bgwriter is not allowed to push page B to

Re: [HACKERS] Problem with dblink regression test

2005-06-27 Thread Jim C. Nasby
I have no clue why the mailling list is eating my original messages, unless it's because I attached a diff to them... in any case, applying http://stats.distributed.net/~buildfarm/patch provides a listing of what all the binaries and libraries in a buildfarm install are linking against. I couldn't