Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Use of NVL()
I need to treat NULLs as empty fields in several places in my database
app, and I am considering using the NVL() function to achieve this,
eg:
select * from fred order by nvl(surname,' ')
or
select * from fred where nvl(surname,' ') < 'Smith'
Is there likely to be a big performance problem from doing this? NVL() is a function so perhaps I will need to create function based indexes to avoid speed problems?
Or is there a configurable parameter somewhere that will treat NULLs as if they were empty fields, something like SQL Server's 'set ANSI NULLs' thing??
Thanks
Andy Received on Tue Feb 05 2002 - 10:06:13 CST