Let x be the number of students attending the school dance.
The total cost for food and drinks is 20x dollars.
The total cost for the hall and food and drinks is 5000 + 20x dollars.
The equation is 5000 + 20x = 20000.
Subtracting 5000 from both sides, we get 20x = 15000.
Dividing both sides by 20, we get x = <<750=750>>750.
Therefore, 750 students can attend the school dance. Answer: \boxed{750}.