I came across the above theorem ( also known as Zermelo's theorem) in real analysis. Since any set can be well-ordered so can the set (0,1) which means there must exist a least element of the set.
That number, say 'p' is either rational or irrational ( I don't think we have a third option here). If 'p' rational, then there must be an irrational number 'q' such that 0< q <p (The proof is trivial) Likewise, if 'p' is irrational then there must exist a 'q' such that '0< q <p'
Thus a contradiction and no such 'p' exists and thus (0,1) is not well-ordered.
What am I missing here?
The well ordering states:
where I write $\tilde{<}$ to distinguish this order from any more common one. Note that the order is not intrinsic to the set - one can well order the rationals, for instance, by saying that, for rationals in lowest terms (with positive denominators), we define $$\frac{a}b\,\tilde{<}\,\frac{c}d$$ if $|a|+|b| < |c|+|d|$ or if $|a|+|b|=|c|+|d|$ and $a<c$. We could get loads of other orders by choosing any bijection $f:\mathbb N\rightarrow\mathbb Q$ and saying that $p_1\,\tilde{<}\,p_2$ whenever $f^{-1}(p_1) < f^{-1}(p_2)$ in the natural numbers - or, in fact, we could do this with any bijection from a set with a known well-order.
None of these would be the usual ordering on the rational numbers - since the usual order is not a well-order, as you prove. The confusion is that your proof regards $(\mathbb Q,<)$ as an ordered set - that is, a set with additional structure on it - whereas the well-ordering theorem regards $\mathbb Q$ itself - a set with no extra structure.
Said otherwise, you proved that $((0,1), <)$ is not a well order for a specific $<$. All the well-ordering theorem says is that there is some $((0,1),\tilde <)$ that is a well-order - so your proof really just rules out one possible order, but doesn't contradict the existence of some other order.