  In this paper we consider arbitrary intervals in the left weak order on the
symmetric group $S_n$. We show that the Lehmer codes of permutations in an
interval form a distributive lattice under the product order. Furthermore, the
rank-generating function of this distributive lattice matches that of the weak
order interval. We construct a poset such that its lattice of order ideals is
isomorphic to the lattice of Lehmer codes of permutations in the given
interval. We show that there are at least
$\left(\lfloor\frac{n}{2}\rfloor\right)!$ permutations in $S_n$ that form a
rank-symmetric interval in the weak order.
