Tracking join and self-join sizes in limited storage