As with any big life change, there is a threshold of benefit that needs to be gotten over before the pain of the change starts to look good. This is why people stay in a broken house instead of moving to a less broken one, why companies resist changing out major systems for more supportable ones, and why people stay in jobs they're unhappy with.
In a perfectly mobile workforce, companies have all the incentive in the world to stay with market-rate raises. Only, there is no such thing as a perfectly mobile workforce. Vendor lock-in applies to paychecks as much as it does to supply contracts. This is how employers can 'get away' with not supplying market-rate raises.
A previous employer of mine had a bit of trouble when they hired me. I was the first new hire in that particular employee class in five years. I got hired at market-rate, as did my new coworkers. Only, my market-rate reflected five years of pay improvements and theirs only reflected standard increments given to all salaried employees.
This got resolved a couple years later when our entire class was increased above what I was being paid. But the fact remains, the only market-rate setting we got was at-hire.
Why did we stay as long as we did?
- The location was fairly remote, so changing jobs to a similar one elsewhere would almost definitely require relocation as well.
- The employer is a traditionally 'sticky' employer (higher-ed).
- The workplace culture was actually pretty nifty.
- The benefits package was really nice, and well above what our market-rate peers were getting.
We started getting attrition when the 2008 recession and associated increase-freeze started being really felt.
Some employers, notably government though large employers are likely similar, can't offer individualized increases, or make 'reclassification' hard due to overly broad job-classes.
There can be significant variation of skill level within a job-class, which further makes reclassification-for-raises (sometimes called 'promotion') difficult.
Certain skills can command a premium over market-rate (Blackboard Admin vs SharePoint Admin), even though abstract job-duties and experience requirements are the same. For organizations that can't offer individualized compensation packages this is a major problem, this is why you see certain skill-sets hired at a higher job-title than they otherwise would be.
There is also more to compensation than mere salary. There are a lot of books out there on non-monetary compensation. For an example of how under-paid techies can stay in one spot despite known pay disparity vs. market-rate, take a look at the previous job I listed above. That job was sticky for a variety of reasons.
There is another value that employers know about called the total cost of compensation for a worker. This value includes things that don't show up in the pay-stub, or if they do they're in the negatives column:
- Employer unemployment insurance contribution
- Employer social-security contribution
- Employer retirement plan contribution
- Employer paid health-care costs
- Employer paid insurances
- Employer paid transit benefits
The HR department of the employer I spoke about above passed out a break-down of each employee's TCC. In my case, the bit that didn't show up in my pay-check came to +35% of my salary. When factoring that against the TCC of my market-rate peers I was actually pretty close to market-rate.
Salary isn't everything.
And then there are the other 'intangibles', which are very hard to quantify, but employers try (hard) to foster. These are value adds to the "benefits of working here" column that don't show up on the pay-check. Employers try to exploit this because most people are not solely in it for the money, and is why most job postings have "and we're a great place to work" somewhere in there.
This is where ping-pong tables and beer in the fridge come from, but it is also how well the office works together. An office that works really well together is one that is retentive.
Your hypothetical female programmer may have found herself a workplace free of the microaggressions that so plagued her previous workplaces (internships, OSS work, pickup work during college, etc), which means she'll happily take a 20% pay cut just so she doesn't have to put up with all of that crap. This is a good example of non-monetary compensation,
If employees aren't asking for raises, or new-hires aren't regularly forcing the organization to up their rates of pay, pay can slip below market-rate due to simple inattention. That's a market force too, it's call inertia.