5. Given vectors
$$
a=(x-y+1, x-y), b=\left(x-y+1,10^{x}\right) \text {. }
$$

Then the number of all integer pairs $(x, y)$ that satisfy $a \cdot b=2012$ is $\qquad$
5.0.

From the problem, we have
$$
\begin{array}{l}
(x-y+1)^{2}+10^{x}(x-y)=2012 \\
\Rightarrow(x-y)\left(x-y+2+10^{x}\right)=2011 .
\end{array}
$$

Obviously, $x \neq 0$, otherwise, $y(y-3)=2011$, this equation has no integer solutions.
If $x>0$, then $10^{x}$ is a positive integer.
Thus, $x-y+2+10^{x}>x-y$.
We get the following two systems of equations:
$$
\begin{array}{l}
\left\{\begin{array}{l}
x-y+2+10^{x}=2011, \\
x-y=1 ;
\end{array}\right. \\
\left\{\begin{array}{l}
x-y+2+10^{x}=-1, \\
x-y=-2011 .
\end{array}\right.
\end{array}
$$

Calculations show that neither system has integer solutions.
In conclusion, the number of integer pairs $(x, y)$ is 0.