Let $f,g:A\rightarrow B$ be two mappings with a coequalizer $q:B\rightarrow Q$. Let $T\subset B\times B$ be the equivalence relation generated by $f(a)\sim g(a)$ for $a\in A$.
Suppose we are given a mapping $\alpha:P\rightarrow Q$. Let $(D,p,\beta)$ be the pullback of $(\alpha,q)$ and $(C,l,\gamma)$ be the pullback of $(\alpha,q\circ f=q\circ g)$. Then there exists unique mappings $h,k:C\rightarrow D$ such that $$\beta\circ h=f\circ\gamma\ \land\ p\circ h=l\ \land\ \beta\circ k=g\circ\gamma\ \land\ p\circ k=l.$$ We want to show that $(P,p)=\text{Coker}(h,k)$.
Let $S\subset P\times P$ be the equivalence relation generated by $h(c)\sim k(c)$ for $c\in C$. Clearly $p:D\rightarrow P$ is surjective. Let $R(x,y):= p(u)=p(v)$ for $u,v\in D$. Then $D/R\cong P$.
Let $K\subset D\times D$ be the equivalence relation generated by $(x,f(a))\sim(x,g(a))$ for $(x,a)\in C$. It can be deduced that $((x,f(a)),(x,g(a)))\in S$ for all $(x,a)\in C$. Thus $K\subset S$.
I want to prove that $R\subset S$. Let $(x,b)\in D$ and $(x',b')\in D$ such that $x=x'$. Then $q(b)=\alpha(x)=\alpha(x')=q(b')$: i.e. $(b,b')\in T$. I am not sure how to use this to show that $((x,b),(x,b'))\in K$.
I don't want to use the "connected components" construction of these generated equivalence relations.
Any hints?