Re: [HACKERS] fix ecpg core dump when there's a very long struct variable name in .pgc file

2012-11-25 Thread Chen Huajun
How on earth did you run into this? :) ooh, first I saw the code accidentally,it looks a bit dangerous and differents from the function ECPGdump_a_simple() above, And then I tried to write a test to raise some errors. Thanks for your comment,I will add the patch into commitfest later. It

Re: [HACKERS] fix ecpg core dump when there's a very long struct variable name in .pgc file

2012-11-25 Thread Michael Meskes
On Sun, Nov 25, 2012 at 08:02:33PM +0800, Chen Huajun wrote: Thanks for your comment,I will add the patch into commitfest later. No need for that, the patch is already committed to the archive. It maybe my first patch for open source. It definitely is then. Michael -- Michael Meskes Michael

Re: [HACKERS] WIP: index support for regexp search

2012-11-25 Thread Alexander Korotkov
On Tue, Nov 20, 2012 at 1:43 PM, Heikki Linnakangas hlinnakan...@vmware.com wrote: Glad to see this patch hasn't been totally forgotten. Being able to use indexes for regular expressions would be really cool! Back in January, I asked for some high-level description of how the algorithm

Re: [HACKERS] WIP: index support for regexp search

2012-11-25 Thread Alexander Korotkov
Hi! On Wed, Nov 21, 2012 at 12:51 AM, Pavel Stehule pavel.steh...@gmail.comwrote: do you plan to support GiST? At first, I would note that pg_trgm GiST opclass is quite ridiculous for support regex search (and, actually for LIKE/ILIKE search which is already implemented too). Because in GiST

Re: [HACKERS] Doc patch: Document names of automatically created constraints and indexes

2012-11-25 Thread Robert Haas
On Sat, Nov 24, 2012 at 6:01 PM, Peter Eisentraut pete...@gmx.net wrote: On Wed, 2012-11-21 at 15:12 -0500, Robert Haas wrote: On Sat, Nov 17, 2012 at 1:22 AM, Peter Eisentraut pete...@gmx.net wrote: On Mon, 2012-11-12 at 11:42 -0600, Karl O. Pinc wrote: Could ALTER TABLE use an option to

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Robert Haas
On Wed, Nov 21, 2012 at 5:10 PM, Peter Eisentraut pete...@gmx.net wrote: Because a strongly-typed system should not cast numbers to strings implicitly. Does the equivalent of the lpad case work in any other strongly-typed programming language? Does any other strongly-typed programming

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Robert Haas
On Thu, Nov 22, 2012 at 10:17 AM, Tom Lane t...@sss.pgh.pa.us wrote: The argument here is basically between ease of use and ability to detect common programming mistakes. It's not clear to me that there is any principled way to make such a tradeoff, because different people can reasonably put

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Josh Berkus
I'd be fine with that if we had a system that allows users to pick the behavior that they want in their particular environment, but in fact our existing system is extremely inflexible. If you start adding additional implicit casts to the system, you get failures trying to invoke

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Thu, Nov 22, 2012 at 10:17 AM, Tom Lane t...@sss.pgh.pa.us wrote: The argument here is basically between ease of use and ability to detect common programming mistakes. It's not clear to me that there is any principled way to make such a tradeoff,

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Peter Geoghegan
On 25 November 2012 23:31, Robert Haas robertmh...@gmail.com wrote: The only other programming language I know of in which you can define what it means to cast between two data types is C++, and it's not generally considered one of that languages better features. AFAICT, they have implicit

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Robert Haas
On Sun, Nov 25, 2012 at 6:46 PM, Tom Lane t...@sss.pgh.pa.us wrote: I think we're talking past each other here. It is unarguable that (as long as there's only one LPAD function) there is only one possible non-error interpretation. However, you are ignoring the real possibility that perhaps

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Robert Haas
On Sun, Nov 25, 2012 at 7:05 PM, Peter Geoghegan pe...@2ndquadrant.com wrote: Well, you can make your class copy-constructable by providing a constructor (and a copy-assignment operator) whose only argument is, say, an int. In additional to that, you could potentially define a conversion

Re: [HACKERS] Materialized views WIP patch

2012-11-25 Thread Marko Tiikkaja
Hi Kevin, On 15/11/2012 03:28, Kevin Grittner wrote: Attached is a patch that is still WIP but that I think is getting pretty close to completion. I've been looking at this, but I unfortunately haven't had as much time as I had hoped for, and have not looked at the code in detail yet. It's

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Peter Geoghegan
On 26 November 2012 00:24, Robert Haas robertmh...@gmail.com wrote: I remember this sort of thing un-fondly from my C++ days, but it doesn't make me like our current behavior any better. You can also make a constructor with a single argument explicit, and thereby prevent implicit conversions.

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: So I think the answer to your question is probably no, purely on the grounds that we have set a new world record for byzantine casting systems. A more fair comparison might be to look at what other SQL systems allow. Oracle, MySQL, and SQL Server

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Robert Haas
On Sun, Nov 25, 2012 at 7:36 PM, Peter Geoghegan pe...@2ndquadrant.com wrote: On 26 November 2012 00:24, Robert Haas robertmh...@gmail.com wrote: I remember this sort of thing un-fondly from my C++ days, but it doesn't make me like our current behavior any better. You can also make a

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Robert Haas
On Sun, Nov 25, 2012 at 6:46 PM, Tom Lane t...@sss.pgh.pa.us wrote: Robert Haas robertmh...@gmail.com writes: I think we're talking past each other here. It is unarguable that (as long as there's only one LPAD function) there is only one possible non-error interpretation. However, you are

Re: [HACKERS] MySQL search query is not executing in Postgres DB

2012-11-25 Thread Robert Haas
On Sun, Nov 25, 2012 at 7:39 PM, Tom Lane t...@sss.pgh.pa.us wrote: I think this is ignoring the fact that we have an extensible type system, and thus a lot more room for problems if we allow too many implicit casts. I don't deny that. It might also be worth noting that some of this

Re: [HACKERS] [WIP] pg_ping utility

2012-11-25 Thread Phil Sorber
I am going to be unavailable until Wednesday, so maybe gives us a few more days for feedback. On Fri, Nov 23, 2012 at 9:48 AM, Michael Paquier michael.paqu...@gmail.com wrote: On Sat, Nov 17, 2012 at 2:48 AM, Phil Sorber p...@omniti.com wrote: On Thu, Nov 15, 2012 at 10:55 PM, Michael

Re: [HACKERS] [WIP] pg_ping utility

2012-11-25 Thread Michael Paquier
On Mon, Nov 26, 2012 at 11:17 AM, Phil Sorber p...@omniti.com wrote: I am going to be unavailable until Wednesday, so maybe gives us a few more days for feedback. Sure no problem. Thanks. -- Michael Paquier http://michael.otacoo.com

Re: [HACKERS] Enabling Checksums

2012-11-25 Thread Jeff Davis
primes, and not seeing any skew), and I didn't see any worrying patterns. Regards, Jeff Davis replace-tli-with-checksums-20121125.patch.gz Description: GNU Zip compressed data checksums-20121125.patch.gz Description: GNU Zip compressed data -- Sent via pgsql-hackers mailing list

Re: [HACKERS] Removing PD_ALL_VISIBLE

2012-11-25 Thread Jeff Davis
rm-pd-all-visible-20121125.patch.gz Description: GNU Zip compressed data -- 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] Removing PD_ALL_VISIBLE

2012-11-25 Thread Tom Lane
Jeff Davis pg...@j-davis.com writes: Now it tries to keep the VM buffer pinned during scans, inserts, updates, and deletes. This should avoid increased contention pinning the VM pages, but performance tests are required. ... Then again, if a 5GB table is being randomly accessed, an extra pin

[HACKERS] Anybody using mutate_eclass_expressions() from add-on code?

2012-11-25 Thread Tom Lane
I looked into the problem reported in bug #7703, namely that queries such as select distinct min(x) from tab; fail if tab is an inheritance tree and an index-optimized plan using MergeAppend is possible. What's happening is that (1) the use of DISTINCT causes us to create an

Re: [HACKERS] fix ecpg core dump when there's a very long struct variable name in .pgc file

2012-11-25 Thread Chen Huajun
(2012/11/25 22:18), Michael Meskes wrote: On Sun, Nov 25, 2012 at 08:02:33PM +0800, Chen Huajun wrote: Thanks for your comment,I will add the patch into commitfest later. No need for that, the patch is already committed to the archive. Oh,I got it,Thanks! -- Regards, Chen Huajun --