Re: How can I change a cast from explicit only to implicit?
От | Julian Scarfe |
---|---|
Тема | Re: How can I change a cast from explicit only to implicit? |
Дата | |
Msg-id | 02d501c4d320$76e1f2f0$0600a8c0@Wilbur обсуждение исходный текст |
Ответ на | How can I change a cast from explicit only to implicit? ("Julian Scarfe" <julian.scarfe@ntlworld.com>) |
Список | pgsql-general |
From: "Tom Lane" <tgl@sss.pgh.pa.us> > > So how can I force a built-in cast to become implicit? > > If you're intent on doing that, you can change its entry in pg_cast. > But I think you'd be far better off to fix your application. Implicit > casts across type categories have a habit of kicking in when you least > expected it, causing the backend to adopt surprising and unpleasant > interpretations of straightforward-looking queries. If you check the > pgsql-bugs archives you will find some of the examples that prompted us > to change this cast to non-implicit... It's a fair point, Tom. Having developed the code with 7.2, we are looking for the simplest way to recreate backward compatible behaviour in 7.4. Sure enough, we'll flag the code for revision next time it gets an overhaul, but a single change to the database would be preferable in the short term. I think the current default of these casts being explicit only is sensible. Thanks Julian
В списке pgsql-general по дате отправления: