Money isn't always everything but it helps! If the money is right there still needs to be some diversity. Speaking from experience, Oracle can be a bit monotonous if you are doing the same thing over and over again. Training in new techniques, giving a new challenge, passing on knowledge to others can all be reasons to go to work and stay there.
Team dynamics are also something to watch. This can be a difficult one. Knowing when there are personaility conflicts is sometimes hard to pinpoint and even tougher to solve. Again it comes back to ensuring that the work is interesting. If it is, and there is enough work to go around, staff don't have time to dwell on things, they would rather work on that new data structure.
Let the team present new ideas, and new technologies, say every 3rd of 4th friday, sit down over 'coffee' or other beverage and get them to present new ideas or technologies that can enhance the way the implementation can be handled.
Lastly... PRAISE. Even the quiet ones who sit in their cubicle all day and don't mingle, like to be recognised for their acheivements. Even if it is a private one on one or announced in the team newsletter.