CREATE CAST requires immutable cast function? 
Author Message
 CREATE CAST requires immutable cast function?

Quote:
Tom Lane writes:
> Perhaps there's a case for prohibiting volatile casts (as opposed to
> stable ones), but I don't really see it.  I'd prefer to just remove
> this restriction.  Comments?

I'm not wedded to it, I just modelled it after the SQL standard, but
evidently the volatility levels are different in detail.  I would disallow
volatile casts in any case.  There ought to be a minimal behavi{*filter*}
contract between creators and users of types.

--

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate

message can get through to the mailing list cleanly



Sun, 20 Feb 2005 02:55:36 GMT
 CREATE CAST requires immutable cast function?

Quote:

> I'm not wedded to it, I just modelled it after the SQL standard, but
> evidently the volatility levels are different in detail.  I would disallow
> volatile casts in any case.  There ought to be a minimal behavi{*filter*}
> contract between creators and users of types.

Shrug ... ISTM the behavior of a type is whatever the type creator says
it should be.  Whether a volatile cast is a good idea is dubious
(I can't think of any good examples of one offhand) but I don't see the
argument for having the system restrict the type creator's choices.

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.***.com/



Sun, 20 Feb 2005 04:10:31 GMT
 
 [ 2 post ] 

 Relevant Pages 

1. CREATE CAST requires immutable cast function?

2. CREATE CAST WITHOUT FUNCTION should require superuserness?

3. check validity of cast before performing cast?

4. Cast and IsNumeric functions don't work!

5. Help with Cast Function and other DTS Problems

6. CAST Function question

7. CAST function on NULL Values

8. CAST function and Date format

9. Need help with type casting on numeric values from AVG aggregate functions

10. cast function to integer

11. Cast function problem


 
Powered by phpBB® Forum Software