I've had this happen when using a specially negotiated fare under a corporate contract. It still earned miles however. I don't think there is a hard and fast rule. If you're really curious call your travel agent and ask, they are the ones who sold you the ticket not United and likely knows the rules better than a random UA phone agent.