I agree, but nulls are valid options in the database. I like the ability to restrict the return type of a function and think altering that to string or any to accommodate nulls is a step backwards and could have negative consequences.
Thanks - Tom -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Patrick McElhaney Sent: Friday, September 16, 2005 1:30 PM To: [email protected] Subject: Re: [CFCDev] <cffunction> return type You should avoid returning null if possible. For numeric values, a common practice is to return a number outside the range of possible values. For example, the find() function in ColdFusion returns the position of the substring in a string, which must be a positive integer. If the substring isn't found, it returns 0. Patrick -- Patrick McElhaney 704.560.9117 http://pmcelhaney.weblogs.us ---------------------------------------------------------- You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email. CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com). CFCDev is supported by New Atlanta, makers of BlueDragon http://www.newatlanta.com/products/bluedragon/index.cfm An archive of the CFCDev list is available at www.mail-archive.com/[email protected] ---------------------------------------------------------- You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email. CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com). CFCDev is supported by New Atlanta, makers of BlueDragon http://www.newatlanta.com/products/bluedragon/index.cfm An archive of the CFCDev list is available at www.mail-archive.com/[email protected]
