Steve Cayford <[EMAIL PROTECTED]> on 25/09/2001 17:28:57 To: [EMAIL PROTECTED] cc: [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: Re: [PHP] Getting my head around nulls On Tuesday, September 25, 2001, at 10:30 AM, [EMAIL PROTECTED] wrote: >> >> Just had a look at manual, ifnull() seems close to useless. However if >> they had NVL(), as Oracle douse.... >> >> NVL( column|litrel, '*null*' ) >> >> This takes a column or literal as its first arg and if arg is null >> returns >> 2nd arg otherwise returns arg. In other words if the column is null it >> is >> replaces by arg2 otherwise it is simply returned. >> > >Um, that's what ifnull() does. At least it works for me. > >-Steve Verry true, sorry, was looking at nullif. Also noticed the if function, can this have more than three parameters. i.e if ( col, 'A', 'Accept', 'C', 'Complete', 'Unknown' ) like Oracle decode. and if elseif else structure. Neb
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]