Why is my left join not returning nulls?
In sql server 2008, I have the following query:

    select		
    	c.title as categorytitle,
    	s.title as subcategorytitle,
    	i.title as itemtitle
    from categories c
    join subcategories s on c.categoryid = s.categoryid
    left join itemcategories ic on s.subcategoryid = ic.subcategoryid 
    	and (ic.isactive = 1 or ic.isactive is null)
    join items i on ic.itemid = i.itemid and i.siteid = 132
    order by c.title, s.title

I am trying to get items in their subcategories, but I still want to return a record if there are no items in the category or subcategory.  Subcategories that have no items are never returned. What am I doing wrong?

Thank you
Why is my left join not returning nulls?
===

In sql server 2008, I have the following query:

    select		
    	c.title as categorytitle,
    	s.title as subcategorytitle,
    	i.title as itemtitle
    from categories c
    join subcategories s on c.categoryid = s.categoryid
    left join itemcategories ic on s.subcategoryid = ic.subcategoryid 
    	and (ic.isactive = 1 or ic.isactive is null)
    join items i on ic.itemid = i.itemid and i.siteid = 132
    order by c.title, s.title

I am trying to get items in their subcategories, but I still want to return a record if there are no items in the category or subcategory.  Subcategories that have no items are never returned. What am I doing wrong?

Thank you