Changes to make performance acceptable when there are 20K+ item sites.
More rework on itemsite query to work reasonably well on large datasets of items.