Let $S$ be the set of all lines in $\mathbf{R}^{2}$ that pass through the origin and have either rational or infinite slope. Show that the usual action of $SL_{2}(\mathbf{Z})$ (the group of $2 \times 2$ integer matrices with determinant $1$) on $\mathbf{R}^{2}$ induces a transitive action of $SL_{2}(\mathbf{Z})$ on $S$.
My Attempt: We need to construct $A\in SL_{2}(\mathbf{Z})$ such that $A\begin{pmatrix} 1\\p \end{pmatrix}= \begin{pmatrix} 1\\q \end{pmatrix}$ for distinct $p,q \in \mathbf{Q}$. But I am not able to construct $A$, give some Hints.
Put some of these facts together.