from Ireland and Rosen: when a prime remains inertial I'm reading Ireland and Rosen's number theory book, and i'm having trouble with proposition 13.1.3 ii):
Let F be $\mathbb{Q(\sqrt d)}$ where $d$ is a square free integer,and $p$ and odd prime, and $P$ a prime ideal of the ring of integers containing $p$. Then If $p$ does not divide the discriminant of F and 
$x^2\equiv d\pmod p$ is not solvable in Z it follows $(p)=P$.
In the proof it supposes the degree of $P$ is 1 so that $D/P$ and $\mathbb{Z}$/$p\mathbb{Z}$ both have $p$ elements. Why is this important? They then go on to state you can find an integer '$a$' such that $a\equiv\sqrt d\pmod P$. How is this so?
And lastly, where do we use the condition $p$ doesn't divide the discriminant?
 A: I guess the proof is by contradiction. You don't want $p$ to divide the discriminant because primes dividing the discriminant are exactly the ramified ones, and so they never remain prime in the ring of integers $\mathcal O_F$ of $F$. Now assume that $p\mathcal O_F$ is not a prime ideal. Then there exists a prime ideal $\mathfrak p\subseteq \mathcal O_F$ such that $\mathfrak p\cap \mathbb Z=p\mathbb Z$ and $\mathcal O_F/\mathfrak p\simeq \mathbb F_p$. Now take the reduction map $\pi\colon \mathcal O_F\to \mathcal O_F/\mathfrak p\simeq \mathbb F_p$. Since $\sqrt{d}\in \mathcal O_F$, it is mapped via $\pi$ to some element $u\in \mathbb F_p$. But then $d$ is mapped to $u^2$, and therefore the equation $x^2=d$ admits the solution $x=u$ in $\mathbb F_p$, and this is a contradiction.
By the way, not only the converse is true as well, but for any number field $K=\mathbb Q(\alpha)$, the splitting behaviour of the minimal polynomial of $\alpha$ modulo $p$ reflects exactly the splitting behaviour of the ideal $(p)$ in the number ring of $K$. You can find a proof of this fact on Marcus' book "Number Fields".
