Is every vector space an injective module? Let R be a commutative ring and $Q$ an $R$-module, we say that $Q$ is injective if it has the property that for all $R$-modules $M$ and $N$ and homomorphisms $$f\ :\ M\to Q$$ and $$\phi\ :\ M\to N$$ such that $\phi$ is injective, there is a homomorphism $\overline{f}\ :\ N\to Q$ such that $\overline{f}\circ \phi =f$.
Let $F$ be a field and let $Q$ be a finite dimensional vector space over $F$, that is, a finitely generated $F$-module.  Prove that $Q$ is injective.
This question is from an old preliminary exam, and I believe I have a solution, which I will provide below, but my proof does not rely on the fact that $Q$ is finite dimensional.  Is it true that all vector spaces are injective?  I didn't think that was true, but I can't see where my proof goes wrong.  I would appreciate either some validation or a reason why my proof fails.  Thanks.
Proof:  Let $M$ and $N$ be vector spaces over $F$.  Let $\{x_i\}_{i\in I}$ be a basis for $M$ where $I$ is some indexing set.  I claim that $\{\phi(x_i)\}_{i\in I}$ is linearly indpendent and spans $\text{im}\phi$.  Indeed,for $\{s_i\}_{i=1}^n\subset I$ and $\alpha_{s_i}\in F$ for each $1\le i\le n$, we have 
$$\sum_{i=1}^n\alpha_{s_i}\phi(x_{s_i})=0$$
$$\implies\phi\left(\sum_{i=1}^n\alpha_{s_i}x_{s_i}\right)=0$$
$$\implies \sum_{i=1}^n\alpha_{s_i}x_{s_i}=0$$
$$\implies \alpha_{s_i}=0\text{ for all }i$$
Where the third line follows from the injectivity of $\phi$.  Hence, $\{\phi(x_i)\}_{i\in I}$ is linearly independent.  To see that this set spans $\phi(M)$, let $y\in \phi(M)$  and write 
$$y=\phi(x)=\phi\left(\sum_{j\in J}^n\alpha_jx_j\right)=\sum_{j\in J}\alpha_j\phi(x_j)\text{ for some finite subset }J\text{ of }I\text{ and }\{\alpha_j\}_{j\in J}\subset F.$$
Extend this set to a basis for $N$.  Define $\overline{f}\ :\ N\to Q$ by $\overline{f}(\phi(x_i))=f(x_i)$ and define $\overline{f}$ to be $0$ on all other basis elements.  It appears that $\overline{f}$ has the property required.  Hence, $Q$ is injective.  
Note that not once did I use the fact that $Q$ had a finite basis.  So, this would imply that all vector spaces are injective.  Note also that I only relied on the fact that $F$ was a field in order to extend the basis.  Could I have also just gotten away with defining $\overline{f}$ to be $0$ on the complement of $\phi(M)$ in order to prove that all free modules are injective?
 A: I'll attempt to give some argument with plain words.
 Look at the following statements: (all assume axiom of choice)
(a) Any set of  linearly independent vectors can be extended to a basis.
(b) A function from one vector space to another,  defined arbitrarily on a set of linearly independent vectors can be extended to the whole space to be a linear transformation
(c) Any subspace of a vector space has a complementary subspace.
From these elementary statements you can conclude the following statement that uses more advanced jargon: Every short exact sequence involving vector spaces and linear transformations is a split sequence.Answer to Injectivity question in your title should now be obvious.
A: Free modules in general are not injective. For example, over $\mathbb{Z}$, a module $M$ being injective is equivalent to being divisible (i.e. for any $n \in \mathbb{N}$, every element of $M$ can be written in the form $m = nx$ for some other $x \in M$.)
Certainly, $\mathbb{Z}$ itself is not divisible.
You needed $F$ to be a field in order to extend bases. But you would also need $F$ to be a field in order to find a complementary submodule of $\phi(M)$ within $N$ (as you suggest in the last question).
A: You're right; your argument works and it is totally irrelevant that $F$ is finite-dimensional.
The assumption that $F$ is a field is essential, though.  You suggest to define $\bar{f}$ to be $0$ on the complement of $\phi(M)$.  If you mean the set-theoretic complement, that typically doesn't give a homomorphism, since there might be two elements of the complement of $\phi(M)$ whose sum is in $\phi(M)$.  If you mean a submodule $K\subseteq N$ such that $N=K\oplus \phi(M)$, then it is possible that no such submodule exists.  For instance, if $R=\mathbb{Z}$, then you might have $M=\mathbb{Z}$, $N=\mathbb{Z}$, and $\phi$ is multiplication by $2$ is $\phi(M)=2\mathbb{Z}$.
