Re: [BUGS] BUG #5487: dblink failed with 63 bytes connection names

2010-06-01 Thread Heikki Linnakangas
On 01/06/10 05:55, Takahiro Itagaki wrote: Takahiro Itagakiitagaki.takah...@oss.ntt.co.jp wrote: Contib/dblink module seems to have a bug in handling connection names in NAMEDATALEN-1 bytes. Here is a patch to fix the bug. I think it comes from wrong usage of snprintf(NAMEDATALEN - 1). It

Re: [BUGS] BUG #5484: sum() bug

2010-06-01 Thread viras
megafon=# \d aaa Table public.aaa Column | Type | Modifiers +--+--- num | real | Yes, really, on smaller quantity of digits of errors is not present. What type of the data is better for using? Numbers up to 10 and accuracy of 2 fractional signs. 30.05.10, 21:43, Tom Lane

Re: [BUGS] BUG #5484: sum() bug

2010-06-01 Thread Robert Haas
On Tue, Jun 1, 2010 at 9:24 AM, viras vi...@yandex.ru wrote: megafon=# \d aaa Table public.aaa Column | Type | Modifiers +--+--- num | real | Yes, really, on smaller quantity of digits of errors is not present. What type of the data is better for using? Numbers up to

Re: [BUGS] BUG #5469: regexp_matches() has poor behaviour and more poor documentation

2010-06-01 Thread Robert Haas
On Mon, May 31, 2010 at 10:11 AM, Bruce Momjian br...@momjian.us wrote: Robert Haas wrote: On Sat, May 29, 2010 at 5:00 PM, Bruce Momjian br...@momjian.us wrote: I have updated the patch, attached, to clarify that this returns text arrays, and that you can force it to always return one row

Re: [BUGS] BUG #5469: regexp_matches() has poor behaviour and more poor documentation

2010-06-01 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: But actually here's an even simpler workaround, which is IMHO less ugly than the original one: SELECT foo, bar, (SELECT regexp_matches(bar, pattern)) FROM table; Doesn't that blow up if the subselect returns more than one row? I think you could make

Re: [BUGS] BUG #5469: regexp_matches() has poor behaviour and more poor documentation

2010-06-01 Thread Bruce Momjian
Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: But actually here's an even simpler workaround, which is IMHO less ugly than the original one: SELECT foo, bar, (SELECT regexp_matches(bar, pattern)) FROM table; Doesn't that blow up if the subselect returns more than one row?

Re: [BUGS] BUG #5469: regexp_matches() has poor behaviour and more poor documentation

2010-06-01 Thread Bruce Momjian
Robert Haas wrote: On Mon, May 31, 2010 at 10:11 AM, Bruce Momjian br...@momjian.us wrote: Robert Haas wrote: On Sat, May 29, 2010 at 5:00 PM, Bruce Momjian br...@momjian.us wrote: I have updated the patch, attached, to clarify that this returns text arrays, and that you can force it to

Re: [BUGS] BUG #5484: sum() bug

2010-06-01 Thread Kevin Grittner
Robert Haas robertmh...@gmail.com wrote: On Tue, Jun 1, 2010 at 9:24 AM, viras vi...@yandex.ru wrote: What type of the data is better for using? Numbers up to 10 and accuracy of 2 fractional signs. numeric is a good choice to avoid loss of precision, but can be a bit slower. You