I need to solve the system
$$\nabla^2 \mathbf{u} = \nabla p \\ \nabla \cdot \mathbf{u} = 0$$
in a subdomain of $\mathbb{R}^3$ with mixed boundary conditions, where $\mathbf{u}$ is vector field and p is a scalar field. Taking the divergence of the first equation, using the definition of vector Laplacian $\nabla^2 \mathbf{u} = \nabla(\nabla \cdot \mathbf{u}) - \nabla \times (\nabla \times \mathbf{u})$, the second equation and the identity $\nabla \cdot (\nabla \times \mathbf{v}) = 0$, we have $$ \nabla \cdot (\nabla^2 \mathbf{u}) = 0 = \nabla \cdot \nabla p = \nabla^2 p$$
I would like to know if the system $$ \nabla^2 \mathbf{u} = \nabla p \\ \nabla^2 p = 0 $$
which was derived using $\nabla \cdot \mathbf{u} = 0$, is equivalent to the first one.
It has the advantage of allowing to solve first for $p$ and then for $\mathbf{u}$, in a decoupled fashion. Unfortunately, according to my numerical experiments and save numerical problems, they are not equivalent, but I don't see why the solution for the second is not a solution for the first one.
I'm not quite sure what you mean by "equivalent" but here is a possible issue:
You have shown $\nabla \cdot u=0 $ $\Rightarrow$ $\nabla^2p=0$, which is correct according to your system. However, the converse does not necessarily hold:
$\nabla^2 p=0$ $\Rightarrow$ $\nabla \cdot (\nabla^2 u) = 0$ which does not necessarily entail that $\nabla \cdot u=0$. In particular, any $u$ satisfying Laplace's equation satisfies this. So the equations $\nabla \cdot u=0$ and $\nabla^2 p=0$ are not "equivalent."