| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> comp.databases.theory -> Re: Eliminating Nulls
It would appear the problem I was thinking about in referencing nulls
in SQL Server has to do with the isnull function and outer joins.
This would not be an issue for those who use a different RDBMS. For those of you who use SQL Server this may be of interest. Using the provided sample databases:
select a.au_id, a.au_lname, title_id = isnull(t.title_id, '-')
from authors a, titleauthor t
where a.au_id *= t.au_id
and a.au_lname like 'S%'
and isnull(t.title_id, '-') = '-'
The results will be three rows will a title_id of '-' however a review of the data will show that author Straight has a title_id value.
The example can be found in Transact-SQL Programming by Kline, Gould, and Zanevsky published by O'Reilly. Again it is not an issue for Oracle, DB2, etc...
![]() |
![]() |