Let $M=\begin{pmatrix} m_{11} & m_{12} \\ m_{21} & m_{22} \end{pmatrix}$ be a matrix in $GL_2^{+}(\mathbb Q)$. We wish to show that $M$ can be decomposed as
$$
M=r\alpha t \tag{1}
$$
where $r\in{\mathbb Q}^{+}$, $\alpha\in SL_2(\mathbb Z)$ and $t\in T$ with
$$
T=\Bigg\lbrace \begin{pmatrix} a & b \\ 0 & d \end{pmatrix}
\ \Bigg| \ a,b,d \in \mathbb Z, gcd(a,b,d)=1 \Bigg\rbrace \tag{2}
$$
Since the (positive) common denominator of the coefficients of $M$ can be put inside $r$ in (1), we can assume without loss that all the $m_{ij}$'s are in $\mathbb Z$.
Then, let $g$ be the (positive) gcd of $m_{11}$ and $m_{21}$. By Bezout's identity, there are integers $u$ and $v$ such that $um_{11}+vm_{21}=g$. Next, introduce the matrix
$$
\beta=\begin{pmatrix} v & u \\ -\frac{m_{11}}{g} & \frac{m_{21}}{g} \end{pmatrix} \in SL_2(\mathbb Z) \tag{3}
$$
Then, by construction, the lower-left coefficient of $\beta M$ is zero :
$$
\beta M = \begin{pmatrix} a' & b' \\ 0 & d' \end{pmatrix} \tag{4}
$$
Next, let $h$ be the (positive) gcd of $a',b'$ and $d'$. If we put
$$
r=h, \ \alpha=\beta^{-1}, t = \begin{pmatrix} \frac{a'}{h} & \frac{b'}{h} \\ 0 & \frac{d'}{h} \end{pmatrix} \tag{5}
$$
we see that (1) is satisfied.
You can exhibit two matrices $A$ and $B$ that satisfy the given equation when $x=0$. You may try to solve the smaller problem
$$
XY-YX=Z:=\pmatrix{1&0\\ 0&-1}\tag{1}
$$
first. Then enlarge $X$ and $Y$ to two $3\times3$ matrices $A$ and $B$ by inserting a zero row and a zero column in the middle of each of $X$ and $Y$.
To solve $(1)$, you may pick an $X$ at random (for this particular $Z$ in $(1)$, don't pick a diagonal matrix; do you know why?) and solve for $Y$. Since $Y$ has four entries, you have a system of four linear equations in four unknowns. It's usually solvable unless the choice of $X$ is very bad. One very good choice for our current problem $(1)$ is $X=\pmatrix{0&1\\ 1&0}$.
If you want to know more about the equation $XY-YX=Z$, see Kahan's paper Only Commutators Have Trace Zero.
Best Answer
Well, you can set $a=c=e=f=0$ and $g=1$, then your matrix becomes $$AB-BA=\begin{pmatrix}b& bh \\ d & -b\end{pmatrix}$$ Now it's easy if $c_{11}\ne 0$.
Else suppose $c_{11}=0$ and set $f=g=h=0$ and $e=1$, then it becomes $$AB-BA=\begin{pmatrix}0& -b \\ c & 0\end{pmatrix}$$ That's all.