This is Exercise 16.5 in Commutative Algebra, Matsumura or Exercise 17.5 in Commutative Ring Theory by the same author.
Let $(A,\frak{m})$ be a Noetherian local ring and $\frak{p}$ be a prime ideal. Show that $$\text{depth }A\leq \text{depth }_{\frak{p}}A + \dim(A/\frak{p})$$
If $\textbf{x}$ is a maximal $A$-regular sequence in $\frak{p}$, then it suffices to show that $\text{depth }A/\textbf{x} \leq \dim A/\frak{p}$ and according to a theorem in Matsumura's book, we may consider showing that $\mathfrak{p} \in \text{Ass } (A/\textbf{x})$. I can see that $\frak{p}$ is in the support of $A/\textbf{x}$ so if $\frak{p}$ is minimal prime ideal above $\textbf{x}A$, then it is a minimal prime in the support, hence necessarily an associated prime of $A/\textbf{x}$. If this is a right approach, can some please give me a hint about showing that $\frak{p}$ is a minimal prime above the ideal $\textbf{x}A$?
Thank you very much.