Re: Can't cast bigint to smallint? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Can't cast bigint to smallint?
Date
Msg-id 26738.1003966899@sss.pgh.pa.us
Whole thread Raw
In response to Can't cast bigint to smallint?  (Philip Warner <pjw@rhyme.com.au>)
Responses Re: Can't cast bigint to smallint?
List pgsql-hackers
Philip Warner <pjw@rhyme.com.au> writes:
> At 16:09 24/10/01 -0400, Tom Lane wrote:
>> Huh?  There's never been a cast from int8 to int2.  I checked 7.0 and
>> 7.1, they both complain as well:

> Is this a policy decision, or just a case where noone has had a chance to
> do it?

Just a missing feature.  The code additions would be trivial --- but
would require an initdb to add the catalog entries.  I'm loath to do it
so close to beta.

>> Where exactly is pg_dump failing?

> The problem in in the code to re-enable triggers:
> ...reltriggers = (select Count(*)....
> So perhaps this version now has Count returning a bigint rather than an int?

Yes, that's what changed.  Perhaps change the code to look like    (select count(*)::integer ...

On the other hand, that's no answer for people trying to load existing
dump files into 7.2.

Perhaps we should just do another catalog update and not worry about it.
We just had one earlier this week, so I suppose another wouldn't make
all that much difference.  Comments?
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: "Triggered data change violation", once again
Next
From: Bruce Momjian
Date:
Subject: Re: [GENERAL] CVS server stumbling?