Subtract from both sides

Divide both sides by

I see that this is not the same as the second formula you posted. Yours was

I don't even have an idea what formula is this. It looks like the change of position formula of a constant acceleration, without time. Which is,

as the change of position,

and as the first and last velocities,

as the constant acceleration