Re: wierd problems with DBI/DBD::pg? - Mailing list pgsql-general

From pmh@edison.ioppublishing.com
Subject Re: wierd problems with DBI/DBD::pg?
Date
Msg-id PGM.20010501102704.23899.357@edison.ioppublishing.com
Whole thread Raw
In response to wierd problems with DBI/DBD::pg?  (Michelle Murrain <mpm@norwottuck.com>)
List pgsql-general
On Mon, 30 Apr 2001 14:50:15 -0400, Michelle Murrain wrote:
> I recently upgraded from 6.5 to 7.1, and it mostly went smoothly (fixed the
> PHP problem, thanks to a list member). But now some of my perl stuff is
> being  a bit strange, and I'm wondering whether other folks have noticed
> strangeness  when they upgraded their Postgres as well as upgraded to the
> new DBD::Pg.
>
> First off, my error strings seem to be cut off - so when an error happens, I
> only get the first few (not at all predictable, either) characters from the
> error string.

Which version of DBD::Pg is it? Versions 0.96 and onwards remove the newlines
from the ends of errors, so that the file and line number which caused them
is appended. My patch (in 0.96 and 0.97) did this by working from the end of
the string, but the patch in 0.98 works from the beginning, and truncates the
error at the first newline. This prevents the core dumps which my patch
caused, but it will truncate multiline errors. If that's what's happening,
I'll submit another patch which starts from the end, but doesn't coredump.

> Second, I have this strange situation where a script that does a query on
> one table of a database gives a reasonable result, but returns an internal
> server  error when a different table is queried. (this worked prior to the
> upgrade) -  plus, the wierd thing is that this script has a graceful exit
> subroutine, and shouldn't just barf like that.

This could be the core dump problem that my patch caused, but you shouldn't
be seeing both core dumps and truncated errors.

--
    Peter Haworth    pmh@edison.ioppublishing.com
"The most important thing in the programming language is the name. A language
 will not succeed without a good name. I have recently invented a very good
 name and now I am looking for a suitable language." -- D. E. Knuth, 1967

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Re: do functions cache views?
Next
From: Tom Lane
Date:
Subject: Re: Improve a query...