2. The number of all positive integer solutions $(x, y, z)$ for the equation $x y+1000 z=2012$ is. $\qquad$
2. 18 .

First consider the positive integer solutions for $x \leqslant y$.
When $z=1$, $x y=1012=4 \times 253=2^{2} \times 11 \times 23$. Hence, $(x, y)=(1,1012),(2,506),(4,253)$,
$$
(11,92),(22,46),(23,44) \text {. }
$$

When $z=2$, $x y=12=2^{2} \times 3$. Hence, $(x, y)=(1,12),(2,6),(3,4)$.
Next, consider the positive integer solutions for $x>y$.
Similarly, there are 9 sets of positive integer solutions.
Therefore, there are a total of $2 \times 9=18$ sets of positive integer solutions.