dbTalk Databases Forums  

Re: [BUGS] function currval(character varying) does not exist, PostgreSQL 8.1 beta3

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss Re: [BUGS] function currval(character varying) does not exist, PostgreSQL 8.1 beta3 in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Tom Lane
 
Posts: n/a

Default Re: [BUGS] function currval(character varying) does not exist, PostgreSQL 8.1 beta3 - 10-20-2005 , 03:55 PM






"Jean-Pierre Pelletier" <pelletier_32 (AT) sympatico (DOT) ca> writes:
Quote:
pstmt = connection.prepareStatement("select currval(?)"); throws =
"function currval(character varying) does not exist"

Is currval(text) gone for good or is this an oversight?
currval(text) is gone for good; the oversight is that we stuck in an
implicit cast from text to regclass, but not one from varchar to
regclass (and the lookup is stupid, there has to be an exact match in
pg_cast).

I think we probably should add an implicit varchar cast. To completely
duplicate the cases in which previous versions would work quietly,
we might need casts from bpchar and name as well, but I'm less excited
about adding those (especially since they would require additional
actual functions, rather than just one more row in pg_cast).

Comments anyone? Do we need to force initdb for this (I suppose so if
we want to be perfectly clean :-()

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.