Alex:
Understanding groupings of NPI's per organization (since they share a tax ID) is something many people (and especially Fred Trotter) are asking for. I'm working on getting something like that made public, but I cannot release that information. I'll be sure and post a link to it here when it becomes available.
As far as answering the question, "Which organizations does a provider works for", that is tricky. That information is not collected in NPPES. It is collected inside PECOS, but only for providers who participate in medicare. It is my understanding that some of this information will become public in a few months but I am not directly involved. Claims data, when you have both a facility NPI and an individual provider might be the best source of knowing who a provider works for.
Hope that helps,
Alan