Re: [BUGS] BUG #5388: bortdagos

2010-03-31 Thread Jaime Casanova
On Wed, Mar 31, 2010 at 10:46 PM, Robert Haas wrote: > On Thu, Mar 25, 2010 at 11:13 AM, bortdagos wrote: >> >> 1980 anthropogenic google environmental depend trends geoengineering > > Thanks for the report.  Will fix. > > no, let it for next version... then we can announce 10.0 -- Atentamente

Re: [BUGS] BUG #5388: bortdagos

2010-03-31 Thread Robert Haas
On Thu, Mar 25, 2010 at 11:13 AM, bortdagos wrote: > > The following bug has been logged online: > > Bug reference:      5388 > Logged by:          bortdagos > Email address:      bortda...@ucla.edu > PostgreSQL version: bortdagos > Operating system:   bortdagos > Description:        bortdagos > D

Re: [BUGS] BUG #5398: psql gives syntax error on .sql files with UTF-8 BOM

2010-03-31 Thread Takahiro Itagaki
"Peter Jukel" wrote: > PostgreSQL version: 8.4 > > The psql command gives syntax errors when fed .sql files that are saved with > encoding "UTF-8" and contain a BOM (byte order marker). When the same file > is saved using the encoding "UTF-8, no BOM", the syntax error is removed. It will be im

Re: [BUGS] dividing money by money

2010-03-31 Thread Andy Balholm
> That's hardly an improvement if you're concerned about lack of > exactness. I know; I lose a couple of digits by using float8 instead of numeric, but it's much simpler and faster, and if it returned numeric people would _think_ it was exact. And if we have a cast to numeric, people who want t

Re: [BUGS] dividing money by money

2010-03-31 Thread Tom Lane
Andy Balholm writes: > I tried rewriting my function to use numeric, but I discovered that numeric > division is not exact. (Otherwise SELECT 1::numeric / 3::numeric would result > in an infinite loop.) So I went back to my float8 version and wrote a cast > from money to numeric. That's hardly

Re: [BUGS] dividing money by money

2010-03-31 Thread Andy Balholm
> Or I guess we could leave this as you've written it and add support > for a cast from money to numeric. I tried rewriting my function to use numeric, but I discovered that numeric division is not exact. (Otherwise SELECT 1::numeric / 3::numeric would result in an infinite loop.) So I went back

Re: [BUGS] dividing money by money

2010-03-31 Thread Andy Balholm
On Mar 31, 2010, at 11:01 AM, Kevin Grittner wrote: > That was my first inclination, but the fact that two different > people talked about using division by '1'::money as a way to convert > money to another type has me nervous about using an approximate > type. Any chance you could rework it usin

Re: [BUGS] dividing money by money

2010-03-31 Thread Kevin Grittner
Andy Balholm wrote: > quotient = (float8)dividend / (float8)divisor; > PG_RETURN_FLOAT8(quotient); That was my first inclination, but the fact that two different people talked about using division by '1'::money as a way to convert money to another type has me nervous about using an approxi

Re: [BUGS] dividing money by money

2010-03-31 Thread Andy Balholm
On Mar 31, 2010, at 7:07 AM, Kevin Grittner wrote: > (I was going to mark the TODO as an easy one.) I thought it would be pretty simple, too, so I decided to go ahead and write and test it as an external module. I think the function definition could be pasted directly into an appropriate pl

Re: [BUGS] BUG #5400: Columns count mismatch in RULE with subquery

2010-03-31 Thread Tom Lane
"Teodor Buchner" writes: > CREATE OR REPLACE RULE move_iteration_1 AS ON INSERT TO a.iteration DO ALSO > INSERT INTO b.iteration(id,date_period_begin) > SELECT (NEW.id,NEW.date_period_begin) FROM a.iteration; Your use of parentheses in the SELECT targetlist is incorrect (and would be with o

Re: [BUGS] dividing money by money

2010-03-31 Thread Kevin Grittner
Chris Travers wrote: > Just thinking about the more general problem and how things could > be handled more gracefully... Sure, but in the meantime, consider: test=# select '12'::money * '2'::numeric; ?column? -- $24.00 (1 row) test=# select '24'::money / '2'::numeric; ?column?

[BUGS] BUG #5400: Columns count mismatch in RULE with subquery

2010-03-31 Thread Teodor Buchner
The following bug has been logged online: Bug reference: 5400 Logged by: Teodor Buchner Email address: t.buch...@autoguard.pl PostgreSQL version: 8.4.1 Operating system: Linux Description:Columns count mismatch in RULE with subquery Details: When SELECT INSERT synta

[BUGS] BUG #5398: psql gives syntax error on .sql files with UTF-8 BOM

2010-03-31 Thread Peter Jukel
The following bug has been logged online: Bug reference: 5398 Logged by: Peter Jukel Email address: pju...@triplehash.com PostgreSQL version: 8.4 Operating system: Mac OSX 10.5.8 Description:psql gives syntax error on .sql files with UTF-8 BOM Details: The psql comm

[BUGS]

2010-03-31 Thread Ing . Marcos Luís Ortíz Valmaseda
-- -- Ing. Marcos Luís Ortíz Valmaseda -- -- FreeBSD Fan/User -- -- http://www.freebsd.org/es -- -- Linux User # 418229-- -- Data