Is the relation of the Dirac delta function correct?
$$ \frac{\partial}{\partial x''}\delta(x''-x') = -\frac{\partial}{\partial x'}\delta(x'-x'').\tag{1} $$
If it is, how to derive the above relation?
Define new coordinates $$x^{\pm}~:=~x^{\prime}\pm x^{\prime\prime}.\tag{A}$$ Then the chain rule yields $$\left(\frac{\partial}{\partial x^{\prime}}+\frac{\partial}{\partial x^{\prime\prime}}\right)\delta(x^{\prime}-x^{\prime\prime}) ~=~ 2\frac{\partial}{\partial x^+}\delta(x^-)~=~0,\tag{B}$$ which is OP's sought-for identity (1).
If you meant $T(x,y) = \delta(x-y)$ the distribution on $\Bbb{R}^2$ defined by $<T,\phi> = \int_{-\infty}^\infty \phi(t,t)dt$ for $\phi \in C^\infty_c(\Bbb{R}^2)$ and $\partial_x T$ the distribution defined by
$<\partial_x T,\phi> =-< T,\partial_x\phi>= -\int_{-\infty}^\infty \partial_x\phi(t,t)dt$
and
$<\partial_y T,\phi> =-< T,\partial_y\phi> =-\int_{-\infty}^\infty \partial_y\phi(t,t)dt$
then $\partial_x\phi(t,t)+\partial_y\phi(t,t) $ is the derivative of $t \mapsto \phi(t,t)$ so that
$<\partial_x T+ \partial_y T,\phi> =- (\lim_{a\to \infty}\phi(a,a)+\phi(-a,-a) )= 0$ thus $\partial_x T+ \partial_y T=0$.
To prove \begin{align} \frac{\partial \delta(x-x_0)}{\partial x} = -\frac{\partial \delta(x-x_0)}{\partial x'} . ~~~~~~~~~~~~~~~~~~~~ \text{(1)} \end{align} Proof: We know that \begin{align} \int f(x) \frac{\partial \delta(x-x_0) }{\partial x}= - f'(x_0) ~~~~~~~~~~~~~~~~~~~~~ \text{(2)} \end{align} Now, \begin{align} & \int f(x) \frac{\partial \delta(x-x_0) }{\partial x_0} dx \\ = & \int f(x) \left( \frac{ \delta(x-(x_0+\epsilon) - \delta(x-x_0) }{(x_0+\epsilon) - x_0} \right) dx \\ = & \frac{ f(x_0 + \epsilon) -f(x_0 ) }{\epsilon} \\ = & f'(x_0), \end{align} which upon comparison with Eq. (2) immediately gives us Eq. (1).