Sufficiency for proof that if $P \in \mathcal{L}(V)$, such that $P^2 = P$ then $V = \text{null}(P) \oplus \text{range}(P).$ I have seen numerous proofs of this result, and understand why they are true.  For instance here and here use the same method - writing $v = Pv + (I - P)v$ and then continuing on in a straightforward manner.  However, I was curious as to why it might not be sufficient to prove the result in the following way:
Since $P^2 = P$, then we have $P(P - I) = 0$, implying that $P = 0$ or $P = I$.  Then if $P = 0$, $\text{null}(P) = V$ and $\text{range}(P) = \{0\}$, so $V = \text{null}(P) \oplus \text{range}(P).$  Else, if $P = I$, then $\text{range}(P) = V$ and $\text{null}(P) = \{0\}$, giving the same desired result.  
What am I missing in the above logic - is there a linear map $P$ that satisfies the above relation but is not the zero function or the identity function?  
Thanks in advance! 
 A: Here's where you go wrong:

We have $P(P-I) = 0$, implying that $P = 0$ or $P = I$

It is true for real numbers (or numbers from your preferred field) that, for $a,b \in \Bbb R$, $ab = 0$ implies that $a = 0$ or $b = 0$.  The analogous statement for matrices, however, is not true.  That is, we can find two non-zero matrices $A,B$ such that $AB = 0$.
For a concrete example, consider the projection matrix
$$
P = \pmatrix{1&0\\0&0}
$$
verify that $P^2 = P$.  However, you can see that we have neither $P = 0$ or $P = I$.  Consequently, $P$ and $(P-I)$ are non-zero matrices which have a product of $0$.
A: Let $$P = \begin{pmatrix} 1 & 0 \\ 0 & 0\end{pmatrix}$$ Then $P^2 = P$ but $P \neq 0,I$.
A: In general an endomorphism $P$ of a vector space satisfying $P^2=P$ is a projection map (which is why it is called$~P$). There is a projection map associated to any decomposition $V=A\oplus B$ of the whole space as a direct sum of (complementary) subspaces $A,B$, called the projection onto $A$ parallel to $B$, and it sends $a+b\mapsto a$ whenever $a\in A$ and $b\in B$ (by the direct sum every vector can be uniquely written as such $a+b$, which shows that such a map is defined; it is easily seen to be linear). Also $A$ and $B$ are eigenspaces for eigenvalues $1$ respectively $B$ (so $P$ is diagonalisable), and therefore they are equal to the image respectively null space of $P$.
If $\dim(V)>1$ there are many such decompositions (infinitely many if the field is infinite), and the cases $P=0$ and $P=I$ correspond only to the trivial cases where $A$ respectively $B$ is $\{0\}$ and the other one is all of $V$, so $P^2=P$ is very far from implying that one is in one of these two cases.
