Re: [PATCHES] WIP Join Removal

2008-09-02 Thread Gregory Stark
CT a.pk FROM a JOIN b USING (x) into SELECT a.pk FROM a WHERE x IN (SELECT x FROM b) -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's 24x7 Postgres support! -- Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-patches

Re: [PATCHES] WIP Join Removal

2008-09-02 Thread Gregory Stark
ossible joins to *add*. So even if the user writes "select * from invoices where customer_id=?" the planner might be able to discover that it can find those records quicker by scanning customer, finding the matching and then using an index to look them up in invoices. -- G

Re: [PATCHES] Explain XML patch v2

2008-07-02 Thread Gregory Stark
"Tom Raney" <[EMAIL PROTECTED]> writes: > This is an update to my EXPLAIN XML patch submitted a few days ago. > > I've added a documentation patch and modified some of the code per comments > by > Gregory Stark. You should update the wiki at http://wiki.po

Re: [PATCHES] [HACKERS] Hint Bits and Write I/O

2008-06-27 Thread Gregory Stark
values were found? If HTSV can hint xmin for a tuple but finds xmax still in progress perhaps that's a good sign it's not worth dirtying the page? -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Get trained by Bruce Momjian - ask me about EnterpriseDB's Post

Re: [PATCHES] [HACKERS] Hint Bits and Write I/O

2008-06-27 Thread Gregory Stark
ld be simpler to have a wrapper function HTSV() macro which passes flexible=true to HTSV_internal(). Then vacuum can call HTSV_internal(). I'm not sure what the performance tradeoff is between having an extra argument to HTSV and having HTSV check a global which messes with optimizations.

Re: [PATCHES] Feature: give pg_dump a WHERE clause expression

2008-06-02 Thread Gregory Stark
he dependencies between them. That's functionality that isn't available elsewhere and can't be reproduced without just reimplementing pg_dump. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's RemoteDBA services! -- Sent via pgsq

Re: [PATCHES] \d+ should display the storage options for columns

2008-05-23 Thread Gregory Stark
=== RCS file: /home/stark/src/REPOSITORY/pgsql/src/bin/psql/describe.c,v retrieving revision 1.173 diff -c -r1.173 describe.c *** src/bin/psql/describe.c 13 May 2008 00:23:17 - 1.173 --- src/bin/psql/describe.c 23 May 2008 18:52:57 - **

Re: [PATCHES] \d+ should display the storage options for columns

2008-05-21 Thread Gregory Stark
"Gregory Stark" <[EMAIL PROTECTED]> writes: > Oleg pointed out to me here that while we have a command to *set* the toast > storage characteristics there's no actual supported way to display the current > settings. > > It seems like this would be a reasonable

[PATCHES] \d+ should display the storage options for columns

2008-05-21 Thread Gregory Stark
ibe.c === RCS file: /home/stark/src/REPOSITORY/pgsql/src/bin/psql/describe.c,v retrieving revision 1.170 diff -c -r1.170 describe.c *** src/bin/psql/describe.c 5 May 2008 01:21:03 - 1.170 --- src/bin/psql/describe.c 21 May 2008 18:07:13

Re: [HACKERS] [PATCHES] WITH RECURSIVE patch V0.1

2008-05-21 Thread Gregory Stark
ry. > > statement_timeout :) Good point. Though it occurs to me that if you set FETCH_COUNT in psql (or do the equivalent in your code ) statement_timeout becomes much less useful. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's

Re: [HACKERS] [PATCHES] WITH RECURSIVE patch V0.1

2008-05-21 Thread Gregory Stark
't have already. The recursive query syntax in the spec actually does include the ability to assign an output column to show what level of recursive iteration you're on. So alternately we could have a GUC variable which just allows the DBA to prohibit any recursive query without such

Re: [PATCHES] [HACKERS] WITH RECURSIVE patch V0.1

2008-05-19 Thread Gregory Stark
at concept with the join plans like merge join or hash join which expect you to be able to be able to process the records in a specific order? It sounds like you might have to keep around a stack of started executor nodes or something but hopefully we can avoid anything like that because, w

Re: [PATCHES] WITH RECURSIVE patch V0.1

2008-05-18 Thread Gregory Stark
d the results. But that's not actually reliable. It's quite possible to have clauses which will limit the output but not in a way the database can determine. Consider for example a tree-traversal for a binary tree stored in a recursive table reference. The DBA might know that th

Re: [PATCHES] WITH RECURSIVE patch V0.1

2008-05-18 Thread Gregory Stark
"David Fetter" <[EMAIL PROTECTED]> writes: > On Mon, May 19, 2008 at 12:21:20AM -0400, Gregory Stark wrote: >> "Zoltan Boszormenyi" <[EMAIL PROTECTED]> writes: >> > Also, it seems there are no infinite recursion detection: >> > >>

Re: [PATCHES] Patch to change psql default banner v6

2008-05-15 Thread Gregory Stark
the top of \?. > > The purpose of 'help' is to provide useful help. If it only says "see \?" > then it's just redirecting you somewhere else, which isn't useful. Haven't been following this thread. Has the idea of making "help" just a

Re: [PATCHES] create or replace language

2008-05-05 Thread Gregory Stark
; the trusted flag as well. I'm not so sure. What about if a PL language wants to include a version number in the language handler? Or if a new version has to change the name for some reason -- perhaps they discover that the old name doesn't work on some linkers for so

Re: [PATCHES] [HACKERS] Proposed patch - psql wraps at window width

2008-04-30 Thread Gregory Stark
\pset format html:autowrap But I think we agree that isn't happening so why spell it "aligned:autowrap" instead of just "wrap"? -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's On-Demand Production Tuning -- Se

Re: [PATCHES] [HACKERS] Proposed patch - psql wraps at window width

2008-04-29 Thread Gregory Stark
HTML" for example, nor would we want there to > be.) Well there's no unaligned HTML or aligned unaligned either... > I think that could be fixed easily by having the syntax be something > like > > \pset format aligned:80 > \pset format aligned:autowrap I suppose. I

Re: [PATCHES] float4/float8/int64 passed by value with tsearchfixup

2008-04-20 Thread Gregory Stark
27;t see any way not to kill v0 for non-integral types if we want to make float4 and float8 pass-by-value. We could leave those pass-by-reference and just make bigint pass-by-value. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's On-Demand P

Re: [PATCHES] float4/float8/int64 passed by value with tsearchfixup

2008-04-20 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >>> Tom Lane wrote: >>>> Specifically, I think what you missed is that on some platforms C >>>> functions pass or return float values differently from si

Re: [PATCHES] float4/float8/int64 passed by value with tsearchfixup

2008-04-18 Thread Gregory Stark
I for i386 does no such thing. You can get behaviour like that from GCC using function attributes like regparam but it's not the default. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's Slony Replication support! -- Sent via pgsql-pat

Re: [PATCHES] Proposed patch - psql wraps at window width

2008-04-18 Thread Gregory Stark
"Bryce Nesbitt" <[EMAIL PROTECTED]> writes: > I asked the folks over at "Experts Exchange" to test the behavior of the ioctl I always thought that was a joke domain name, like Pen Island.com. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com

Re: [PATCHES] Proposed patch - psql wraps at window width

2008-04-18 Thread Gregory Stark
ll be formatted with a line length appropriate to the current terminal (using an ioctl(2) if available, the value of $COLUMNS, or falling back to 80 characters if neither is available). Cat pages will only be saved when the default formatting can be used, that is when

Re: [PATCHES] Proposed patch - psql wraps at window width

2008-04-17 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >> Also, how would you suggest figuring the width to use for output going to a >> file? ioctl is irrelevant in that case, imho it should just default to 80 >> colu

Re: [PATCHES] Proposed patch - psql wraps at window width

2008-04-17 Thread Gregory Stark
he ioctl's going to get back but it's unlikely to be right. In any case I may want to format the output to a width narrower than the window because I'm going to narrow it. Also, how would you suggest figuring the width to use for output going to a file? ioctl is irrelevant in th

Re: [PATCHES] Improve shutdown during online backup

2008-04-16 Thread Gregory Stark
is have a separate program (I would write a client but a server-side function would work too) to kick off users based on various criteria you can specify. Then you can put in your backup scripts two commands, one to kick off idle users and then do a smart shutdown. -- Gregory Stark EnterpriseD

Re: [PATCHES] datum passed to macro which expects a pointer

2008-04-12 Thread Gregory Stark
es > pass by value instead of pass by reference. There was a patch to do this posted recently here as well. http://archives.postgresql.org/pgsql-patches/2008-03/msg00335.php Hm. I suppose it's true that you could make Datum 64-bit even on 32-bit machines and make int8 and float8 pas

Re: [PATCHES] EXPLAIN progress info

2008-04-10 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >> I think a better way to get a real "percentage done" would be to add a method >> to each node which estimates its percentage done based on the percentage done >

Re: [PATCHES] EXPLAIN progress info

2008-04-09 Thread Gregory Stark
"Heikki Linnakangas" <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> Gregory Stark <[EMAIL PROTECTED]> writes: >>> There are downsides: >> >> Insurmountable ones at that. This one already makes it a non-starter: >> >>>

Re: [PATCHES] EXPLAIN progress info

2008-04-08 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >> I know I should still be looking at code from the March Commitfest but I was >> annoyed by this *very* FAQ: > >> http://archives.postgresql.org/pgsq

[PATCHES] EXPLAIN progress info

2008-04-08 Thread Gregory Stark
uch as BSD where the default will probably be C-t). But no reviewing it until we finish with the March patches! Do as I say, not as I do :( explain-progress.diff.gz Description: Binary data -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about Enterprise

Re: [PATCHES] Partial match in GIN

2008-04-08 Thread Gregory Stark
verloading the comparison function. Then if the support function is there it supports that type of scan and if it doesn't then it doesn't, rather than depending on a magic third argument to completely change behaviour. You can always share code using an internal function or if the behavi

Re: [PATCHES] Indexam API changes

2008-04-08 Thread Gregory Stark
han have to wait for the complete index scan to finish before processing any. Is that it? In general I think we need to be more open to incremental improvements. I think there are several fronts on which we refuse patches to do X because it's useless without Y and have nobody working on Y bec

Re: [PATCHES] Database owner installable modules patch

2008-04-06 Thread Gregory Stark
hich case we wouldn't need an uninstall script at all. The hacks to do this seem pretty dirty but on the other hand the idea of having modules consist of a bunch of objects rather than arbitrary SQL actually seems cleaner and more robust. -- Gregory Stark EnterpriseDB http://www.

Re: [PATCHES] Ordered Append WIP patch v1

2008-04-06 Thread Gregory Stark
"Bruce Momjian" <[EMAIL PROTECTED]> writes: > Alvaro Herrera wrote: >> Gregory Stark wrote: >> > >> > Here's the WIP patch I described on -hackers to implemented "ordered" >> > append >> > nodes. >> >> D

Re: [PATCHES] Expose checkpoint start/finish times into SQL.

2008-04-04 Thread Gregory Stark
record that the last checkpoint record *points to*. That represents the "guarantee" that the database is making to the sysadmin about data integrity. Everything before that time is guaranteed to have reached data files already. Everything after it may or may not be in the data files and has

Re: [PATCHES] psql command aliases support

2008-04-03 Thread Gregory Stark
"Bernd Helmle" <[EMAIL PROTECTED]> writes: > --On Donnerstag, April 03, 2008 14:36:59 +0100 Gregory Stark > <[EMAIL PROTECTED]> wrote: > >>> \o foo instead of \i foo -- check your keyboard layout >> >> The point is here you've typed a diffe

Re: [PATCHES] psql command aliases support

2008-04-03 Thread Gregory Stark
kages where packagename like :1 \setquery bbdb select * from bbdb where name like :1 \query deb postgres \query bbdb peter to run a saved query. I'm not attached to "setquery" though. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's RemoteDBA services! -- Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-patches

Re: [PATCHES] psql command aliases support

2008-04-03 Thread Gregory Stark
going?' #= select 'what happened to my ldd file?' -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's RemoteDBA services! -- Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-patches

Re: [PATCHES] Consistent \d commands in psql

2008-04-02 Thread Gregory Stark
k the same logic as \df applies for those other things too. \dt pg_class should "just work". And if you create a macaddr data type it doesn't seem like too much of an imposition to play it safe and have \dT macaddr show the user that there are now two matching data types. So I guess I

Re: [PATCHES] psql command aliases support

2008-04-02 Thread Gregory Stark
wful. Even if it's not implemented right away I think we should figure out what the syntax would be for passing arguments to be interpolated into the query before backing ourselves into a corner. I can't imagine much of a use case for being able to alias backslash commands themselves. Th

Re: [PATCHES] Consistent \d commands in psql

2008-04-01 Thread Gregory Stark
nd proposal. I prefer it to my own first proposal or any of the others. I admit I was thinking primarily of non-globbing cases for pattern. As in, I would want \df rtrim to "work". I suppose it could be annoying to have to type \df public.* -- there's nothing stopping us from

Re: [PATCHES] Consistent \d commands in psql

2008-03-31 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >> One --perhaps nice, perhaps not-- property of this is that if you defined a >> function named "rtrim" and then did "\df rtrim" it would show you _both_

Re: [PATCHES] Consistent \d commands in psql

2008-03-31 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >> It might be cute to see if the pattern matches any user functions and if not >> try again with system functions. So you would still get results if you did >> "\df

Re: [PATCHES] Consistent \d commands in psql

2008-03-31 Thread Gregory Stark
ust your user functions. That's a real headache and it gets worse as we add more and more system functions too. It might be cute to see if the pattern matches any user functions and if not try again with system functions. So you would still get results if you did "\df rtrim&

Re: [PATCHES] [WIP] Keeping track of snapshots

2008-03-28 Thread Gregory Stark
ction which needs a snapshot... AFAICT VACUUM had better not ever need a snapshot because its xmin isn't included in other vacuum commands' globalxmin so there's no guarantee that if it had a snapshot that the tuples visible in that snapshot wouldn't disappear out from

Re: [PATCHES] Re: int8/float8/time/timestamp[tz]/float4 passed by value, was Re: Fix HAVE_LONG[_LONG]_INT_64 to really define to 1

2008-03-24 Thread Gregory Stark
"Zoltan Boszormenyi" <[EMAIL PROTECTED]> writes: > Zoltan Boszormenyi írta: >> Gregory Stark írta: >>> 4) Your problems with tsearch and timestamp etc raise an interesting >>> problem. >>>We don't need to mark this in pg_control because

Re: [PATCHES] int8/float8/time/timestamp[tz]/float4 passed by value, was Re: Fix HAVE_LONG[_LONG]_INT_64 to really define to 1

2008-03-24 Thread Gregory Stark
g I've been wanting to do for a while and basically the same approach I would have taken. It seems sound to me. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's RemoteDBA services! -- Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-patches

Re: [PATCHES] int8/float8/time/timestamp[tz]/float4 passed by value, was Re: Fix HAVE_LONG[_LONG]_INT_64 to really define to 1

2008-03-24 Thread Gregory Stark
d correct every time and now > because of the passbyval nature of int8, the !AggState version is not slower > than using the pointer directly. Does this mean count() and sum() are slower on a 32-bit machine? -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Get train

Re: [PATCHES] Logging conflicted queries on deadlocks

2008-03-21 Thread Gregory Stark
"Gregory Stark" <[EMAIL PROTECTED]> writes: > There's no way the other transaction's timeout could fire while we're doing > this is there? Are we still holding the lw locks at this point which would > prevent that? Ah, reading the patch I see comments in

Re: [PATCHES] Logging conflicted queries on deadlocks

2008-03-21 Thread Gregory Stark
at. As the patch stands, every query involved > in the deadlock will be reported, which might be undesirable. We could > make the test use the outermost session user's ID instead of current > ID, but that might only move the security risks someplace else. > Thoughts? Perhaps

Re: [PATCHES] Proposed patch to change TOAST compression strategy

2008-02-18 Thread Gregory Stark
ind a few backreferences. I'll try some tests and see. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's On-Demand Production Tuning ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings

Re: [PATCHES] Proposed patch for 8.3 VACUUM FULL crash

2008-02-11 Thread Gregory Stark
utside of CVS in this case we perhaps suffered from the opposite problem. The patch was fairly heavily tested on this end before it was posted and I'm not sure those tests have been repeated since the merge. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com

Re: [PATCHES] Proposed patch for bug #3921

2008-02-03 Thread Gregory Stark
Kind of verbose but nice that it's the same syntax as constraints. Not sure how easy it would be to shoehorn into t he like processing, I could look at that if you want. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's Re

Re: [PATCHES] Bitmap index scan preread using posix_fadvise

2008-02-01 Thread Gregory Stark
ray(select (1+random()*100)::integer from generate_series(1,100))); bitmap-preread-v8.diff.gz Description: Binary data -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's 24x7 Postgres support! ---

Re: [PATCHES] Bitmap index scan preread using posix_fadvise

2008-02-01 Thread Gregory Stark
"Gregory Stark" <[EMAIL PROTECTED]> writes: > Aside from some autoconf tests and the documentation for the GUC I > think it's all in there. I'm sorry, it seems I accidentally grabbed an old tree to generate this patch. I'll send along a better more recen

[PATCHES] Bitmap index scan preread using posix_fadvise (Was: There's random access and then there's random access)

2008-01-30 Thread Gregory Stark
int32 n = PG_GETARG_INT32(0); int32 lobound = PG_GETARG_INT32(1); int32 hibound = PG_GETARG_INT32(2); Datum *elems = palloc(sizeof(Datum) * n); ArrayType *retval; int i; for (i=0; i -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about Ent

Re: [PATCHES] [8.4] Updated WITH clause patch (non-recursive)

2008-01-30 Thread Gregory Stark
lan. Or somehow to check whether it wouldn't be faster to just inline the memoized node directly because perhaps there's a path available which would work for this read of it. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's On-De

Re: [PATCHES] Proposed patch: synchronized_scanning GUC variable

2008-01-29 Thread Gregory Stark
skew, plus page headers, and every record will have a different system data such as xmin for one. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Get trained by Bruce Momjian - ask me about EnterpriseDB's PostgreSQL training! ---(end of broadcast)--- TIP 6: explain analyze is your friend

Re: [PATCHES] WIP: plpgsql source code obfuscation

2008-01-28 Thread Gregory Stark
exempt free software from any crypto export licenses. Doesn't stop some other country from coming up with the same idea of course but we don't generally worry about what laws some hypothetical country might introduce at some point in the future. That way lies madness. -- Gregory Sta

Re: [PATCHES] WIP: plpgsql source code obfuscation

2008-01-28 Thread Gregory Stark
has any opportunity to substitute its result for the original in prosrc. That might be interesting for other applications like compiled languages, though I think they would still want to save the source in prosrc and the bytecode in probin. -- Gregory Stark EnterpriseDB http://www.en

Re: [PATCHES] WIP: plpgsql source code obfuscation

2008-01-28 Thread Gregory Stark
at is advantage? It wouldn't require any core changes. It would be just another PL language to load which can be installed like other ones. This could be a big advantage because it doesn't look like there is a lot of support for putting th obfuscation directly into the core

Re: [PATCHES] WIP: plpgsql source code obfuscation

2008-01-28 Thread Gregory Stark
ass it to the normal plperl. In such a scheme I think you would put the key in an attribute of the language. Either in pg_lang or some configuration location which the obfuscate:plperl interpreter knows where to find. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me abo

Re: [PATCHES] Proposed patch: synchronized_scanning GUC variable

2008-01-27 Thread Gregory Stark
dump disable >> sync scans so that it will reliably preserve row ordering. This is a >> pretty trivial patch, but seeing how late we are in the 8.3 release >> cycle, I thought I'd better post it for comment anyway. > > +1 I liked the "synchronized_sequential_sc

Re: [PATCHES] [8.4] Updated WITH clause patch (non-recursive)

2008-01-27 Thread Gregory Stark
taking "with" as a reserved word. I still hope to do recursive queries for 8.4 so I don't have strong feelings for this part either way. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's On-Demand Production Tuning -

Re: [PATCHES] [HACKERS] OUTER JOIN performance regression remains in 8.3beta4

2008-01-09 Thread Gregory Stark
e could use to make this decision instead of the number of clauses? I would suggest the selectivity but from the sound of it that's not going to help at all. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's RemoteDBA services! --

Re: [PATCHES] Proposed patch to make mergejoin cost estimationmore symmetric

2007-12-07 Thread Gregory Stark
ble explain plan we could stuff a lot more data in there and have it be the UI's responsibility to decide what data to display. When that happens it would be nice to have the raw data used to generate the cost estimations. At least the most important factors. -- Gregory Stark Enterpr

Re: [PATCHES] Proposed patch to make mergejoin cost estimation more symmetric

2007-12-07 Thread Gregory Stark
ainst a single-row table. The comments make me think you ran them but just didn't show them though. What about a merge join against an empty table? I suppose there would just be no statistics? -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about En

Re: [PATCHES] Better default_statistics_target

2007-12-05 Thread Gregory Stark
unevenly distributed then we need enough buckets to be able to distinguish the dense areas from the sparse areas. Perhaps something like starting with 1 bucket, splitting it into 2, seeing if the distributions are similar in which case we stop. If not repeat for each bucket. -- Gregory Stark

Re: [PATCHES] [GENERAL] Empty arrays with ARRAY[]

2007-11-30 Thread Gregory Stark
ol = array[]; INSERT INTO foo (col) VALUES (array[]); could be allowed if they could be contrived to introduce an assignment cast. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's RemoteDBA services! ---(end of broadc

Re: [PATCHES] [DOCS] Partition: use triggers instead of rules

2007-11-29 Thread Gregory Stark
artitions. Then let constraint_exclusion kick in to narrow down which partitions should actually receive the updates and deletes. I think triggers are the only solution for insert though. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB&#

Re: [PATCHES] [DOCS] Partition: use triggers instead of rules

2007-11-29 Thread Gregory Stark
es of data for both OLTP and DSS systems. I tend to be happier recommending triggers over rules if only because rules are just harder to understand. Arguably they don't really work properly for this use anyways given what happens if you use volatile functions like random() in

Re: [PATCHES] [DOCS] Partition: use triggers instead of rules

2007-11-29 Thread Gregory Stark
"Joshua D. Drake" <[EMAIL PROTECTED]> writes: > Tom Lane wrote: > >> A trigger will probably beat a rule for inserts/updates involving a small >> number of rows. > > Which is exactly what partitioning is doing. Say what? -- Gregory Stark Enterpris

[PATCHES] Ordered Append WIP patch v1

2007-11-22 Thread Gregory Stark
Here's the WIP patch I described on -hackers to implemented "ordered" append nodes. merge-append-v1.diff.gz Description: Binary data -- Gregory Stark EnterpriseDB http://www.enterprisedb.com Ask me about EnterpriseDB's Slony

Re: [PATCHES] Better default_statistics_target

2007-11-19 Thread Gregory Stark
ict. On the other hand longer fields take more space and take longer to compare so to make consistent use of resources you would want to avoid storing and comparing large numbers of them whereas you could afford much larger targets for small quick columns. -- Gregory Stark Ente

Re: [PATCHES] V0.2 patch for TODO Item: SQL-language referenceparameters by name.

2007-11-03 Thread Gregory Stark
or other interfaces like it will run into problems when the driver misinterprets the parameters. > I think it would be a very bad idea > to require that people use the function name in parameters, I think were talking about only allowing it to disambiguate if the name is shadowed by a

Re: [PATCHES] Autovacuum cancellation

2007-10-26 Thread Gregory Stark
h to apply the patch from memory -- clearly not. I assume the right thing happens if multiple deadlock check signals fire for the same autovacuum? -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)---

Re: [PATCHES] Autovacuum cancellation

2007-10-25 Thread Gregory Stark
7;m not sure that's a case we really need to worry about. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail com

Re: [PATCHES] Win32: Minimising desktop heap usage

2007-10-23 Thread Gregory Stark
n't necessarily have the most up to date value if it's been changed. But it's not something you're likely to change and you can always adjust the environment variable manually to fix the problem. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com -

Re: [PATCHES] Assertion failure with small block sizes

2007-10-15 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >> If I push the TOAST_TUPLES_PER_PAGE up to 16 I get another failure on the >> same >> line from trying to toast a sequence. If I add RELKIND_SEQUENCE to the >> a

Re: [PATCHES] Assertion failure with small block sizes

2007-10-14 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >> Testing Postgres with a small block size runs into an assertion failure when >> it tries to toast a pg_proc tuple during initdb. I think the assertion is >> just >

[PATCHES] Assertion failure with small block sizes

2007-10-14 Thread Gregory Stark
template1 database in /home/stark/src/local-HEAD/pgsql/src/test/regress/./tmp_check/data/base/1 ... TRAP: FailedAssertion("!(rel->rd_rel->relkind == 'r')", File: "tuptoaster.c", Line: 440) --- tuptoaster.c13 Oct 2007 22:34:06 +0100 1.78 +++ tupt

[PATCHES] Packed varlena tuptoaster.c oops

2007-10-11 Thread Gregory Stark
Caught this in my testing with enhanced debugging checks. Index: src/backend/access/heap/tuptoaster.c === RCS file: /home/stark/src/REPOSITORY/pgsql/src/backend/access/heap/tuptoaster.c,v retrieving revision 1.77 diff -u -r1.77

Re: [PATCHES] [HACKERS] 'Waiting on lock'

2007-09-25 Thread Gregory Stark
system but don't want to block on any user-profiles which are locked by active users -- especially if you use database locks for user-visible operations which users can drag out for long periods of time. (Not saying I agree with that design but there are arguments for it and

[PATCHES] Eliminate more detoast copies for packed varlenas

2007-09-21 Thread Gregory Stark
files changed, 5 insertions(+), 364 modifications(!) packed-varlena-efficiency_v0.patch.gz Description: Binary data -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [PATCHES] [COMMITTERS] pgsql: Avoid possibly-unportable initializer, per buildfarm warning.

2007-09-17 Thread Gregory Stark
==== RCS file: /home/stark/src/REPOSITORY/pgsql/src/backend/tsearch/dict_thesaurus.c,v retrieving revision 1.3 diff -c -r1.3 dict_thesaurus.c *** src/backend/tsearch/dict_thesaurus.c25 Aug 2007 00:03:59 - 1.3 --- src/backend/tsearch/dict_thesaurus.c1

Re: [PATCHES] PL/TCL Patch to prevent postgres from becoming multithreaded

2007-09-14 Thread Gregory Stark
come in from people who are more familiar with it than us. In my experience that's how new maintainers for modules of free software are often found anyways. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [PATCHES] WIP patch for latestCompletedXid method of computing snapshot xmax

2007-09-11 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > Gregory Stark <[EMAIL PROTECTED]> writes: >> "Tom Lane" <[EMAIL PROTECTED]> writes: >>> This patch implements Florian's idea about how to manage snapshot xmax >>> without the ugly and p

Re: [PATCHES] Yet more tsearch refactoring

2007-09-11 Thread Gregory Stark
rdware but (aside from believing the code will work of course) we should at a minimum be certain that the build farm will detect the problem. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 9: In versions

Re: [PATCHES] HOT patch - version 15

2007-09-11 Thread Gregory Stark
tid (and posid) should always be 4-byte aligned. So actually it would never cross a hardware sector boundary. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 1: if posting/reading through

Re: [PATCHES] HOT patch - version 15

2007-09-10 Thread Gregory Stark
the line pointers in question to anything else. (because your pin prevents the vacuum lock from coming in and trying to mark it unused). -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 9: In

Re: [PATCHES] HOT patch - version 15

2007-09-10 Thread Gregory Stark
prunes per update instead of a potentially unbounded number of prunes. This seems like a further optimization to think about after we have a place to trigger the pruning where it'll do the most good. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---

Re: [PATCHES] WIP patch for latestCompletedXid method of computing snapshot xmax

2007-09-07 Thread Gregory Stark
> things to get bootstrap and prepared transactions to work, but on the > whole it seems at least as clean as the code we have now. Comments? Just that it will be fascinating to see what effects this has on the benchmarks. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com

Re: [PATCHES] HOT patch - version 15

2007-09-05 Thread Gregory Stark
"Pavan Deolasee" <[EMAIL PROTECTED]> writes: > On 9/6/07, Gregory Stark <[EMAIL PROTECTED]> wrote: > >> Ah, as I understand it you can't actually do the pruning then because the >> executor holds references to source tuple on the page. In other words

Re: [PATCHES] HOT patch - version 15

2007-09-05 Thread Gregory Stark
se the executor holds references to source tuple on the page. In other words you can never "get the vacuum lock" there because you already have the page pinned yourself. -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--

Re: [PATCHES] HOT patch - version 15

2007-09-05 Thread Gregory Stark
Whether the index lookup should prune the heap chain is another issue. Pruning chains is kind of the whole point of the exercise no? -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 7: You can help support the PostgreSQL project by donating at http://www.postgresql.org/about/donate

Re: [PATCHES] HOT documentation README

2007-09-04 Thread Gregory Stark
too? Or would it be too much extra overhead? -- Gregory Stark EnterpriseDB http://www.enterprisedb.com ---(end of broadcast)--- TIP 4: Have you searched our list archives? http://archives.postgresql.org

Re: [PATCHES] HOT documentation README

2007-09-04 Thread Gregory Stark
outstanding commands using early snapshots then subsequent planning ought to be able to use the index. Even if outstanding commands are using old snapshots if we can be sure they can't use the new plan then it would still be safe to use the index in the new plan. Also in SERIALIZABLE mode those

Re: [PATCHES] HOT documentation README

2007-09-04 Thread Gregory Stark
ut CREATE INDEX, and > worked up an updated README. Comments? Corrections? You should also take the appendix to Heikki's README about CREATE INDEX that I wrote. > > I plan to put this in src/backend/access/heap/README.HOT. -- Gregory Stark EnterpriseDB http://ww

Re: [PATCHES] Buglet in "Sort Method" explain output in degenerate case

2007-09-01 Thread Gregory Stark
h. Index: src/backend/utils/sort/tuplesort.c ======= RCS file: /home/stark/src/REPOSITORY/pgsql/src/backend/utils/sort/tuplesort.c,v retrieving revision 1.77 diff -c -r1.77 tuplesort.c *** src/backend/utils/sort/tuplesort.c 7 Jun 2007 19:19:57 - 1.77 --- src/backe

  1   2   3   4   >