This might lead to a pedestrian example: Let $R$ be a local ring with maximal ideal $m$, $X$ a scheme, and $f:Spec(R) \to X$ a map. If $U$ is an open subscheme of $X$ containing $f(m)$ then $f$ factors through a map $Spec(R) \to U$. Thus if we have two arrows $g,h:Y \to Spec(R)$, the coequalizer $c: Spec(R)\to C$ must be an affine scheme (else $c$ would factor strictly through an affine neighborhood $U$ of $c(m)$, and $U$ would be a "better coequalizer" than $C$). So If $Y=Spec(B)$ is also affine, then the coequalizer of $g,h$ is just $Spec(A)$ where A $A$ is the equalizer of $g^\sharp,h^\sharp$.
let R be k[x_i]_(x_i) $k[x_i]_{(x_i)}$ and S'=k[y_i,z_i]_(y_i,z_i). $S'=k[y_i,z_i]_{(y_i,z_i)}.$ there are two maps $g',h':R \to S S$ given by
g'(x_i)
$$g'(x_i) = y_i
h'(x_i) y_i$$
$$h'(x_i) = z_iz_i$$
suppose that I $I$ is an ideal of R. $R$. let I_y, I_z $I_y, I_z$ be the ideals generated by g(I) $g(I)$ and h(I) $h(I)$ respectively and let $S = S'/(I_y + I_z)I_z)$. write g $g$ and h $h$ for the induced maps $R \to SS$. the equalizer of g,h $g,h$ is just $A = k + I \subset RR$. it seems unlikely to me that $spec R \to spec A A$ is surjective for all choices of I.$I$.

