Unfortunately, in many larger companies (with hundreds of employees), there are so many layers of managerial bullshit that prevent that. People who actually know the employee who wants to leave (direct managers) often don't have power to decide the salary etc, and people who have that power are at the other end of company and they are not concerned about the productivity, etc., just making spreadsheets green.
I know a large company, where pay raises are almost non existent, and it's normal for employees to leave in 6-12 months. Needless to say, the productivity there is pretty bad.