I used to own an E34 535, I had the same problem too. And the problem was the same as robbo00, the pump in that car was located just outside of the resevoir, which in that car was partitioned, with a majority of it being for the windscreen washer, the rest, about 1.8 liters, if memory serves me, was for the headlamps. That portion by the way was to be filled with a special concentration washer purchased through the dealer so I always just put regular washer fluid in it.
Anyway..., the pump had died at some point and I ordered another through someone online, maybe BavAuto or something for like $40 or so, and it went in rather easy. I dont imagine its a much different set up on your X5 other that it maybe buried a little more. I currently have an E71 X5 and those headlamp washers are quite different than the previous models.